Posts Tagged

php

Creating dynamic sitemap with Codeigniter

Recipe for creating Dynamic sitemap with CodeIgniter. Like yoursite.com/sitemap.xml Example. Suppose you have an articles blog where url for each article is by article ID Like yoursite.com/123 . All articles are stored in articleTable of the database. First Create a model to get URLs. Create a file named url_model.php in application/models directory. Get Urls from database <?php class Url_model extends CI_Model{     public function __construct(){…

Read More

Enable php cURL in Ubuntu

When i used Windows enable cURL was little bit tricky, but its so simple in Linux. I am using Ubuntu 12.04 LTS now a days, and when i need cURL enable in my system I run the following command in my Terminal and restart Apache. sudo apt-get install php5-curl to restart apache, sudo service apache2…

Read More