Posted by: Anil Kumar Panigrahi in: ● July 31, 2010
Hi friends,
Recently i changed my facebook page with username. I want to share with you all how to set username to facebook pages. In the past pages URL like /pages/id=11111111 , Now we can change it by following procedure.
1) Create facebook page and keep on postings.
2) When 25 friends connected with your page then we [...]
Posted by: Anil Kumar Panigrahi in: ● July 2, 2010
Hi friends,
In this post i want to explain how to create rss feeds using php code and get the data from mysql table.
1) Connect to database:
We already discussed about how to connect database using php code.See the following code to connect database:
1
2
3
4
5
6
7
8
9
10
11
<?php
DEFINE (’DB_USER’, ‘root’);
DEFINE (’DB_PASSWORD’, ‘root’);
DEFINE (’DB_HOST’, ‘localhost’);
DEFINE (’DB_NAME’, ‘rss’);
// Make the connnection and then [...]
Posted by: Anil Kumar Panigrahi in: ● June 27, 2010
The following script to copy the text from remote url using php code.
<?php
$regex = ‘/]*>(.*<\/body>/smi’;
/*END config, BEGIN html*/
$data = file_get_contents($siteName) or die(’Cannot read ‘ . $siteName);
preg_match($regex, $data, $cleanData);
if(!empty($cleanData))
$data = $cleanData[1];
echo $data;
?>
<!– HTML Footer Data here… –>
This is simple copy text from another site, but it will be useful for who are new to php.
Posted by: Anil Kumar Panigrahi in: ● March 28, 2010
Hi friends ,
the following script will discuss for how to implement google map in smarty application.
1) Sign up for API key of googlemap
http://code.google.com/apis/maps/signup.html
2) Create a google map class.
3) Create a tpl file, and add below code :
{php}
$key=”Your API Key”;
$gm = & new EasyGoogleMap($key);
$gm->SetMarkerIconStyle(‘STAR’);
$gm->SetMapZoom(10);
$city =”baruva”;
$country = “india”;
$gm->SetAddress($city,$country);
$gm->SetInfoWindowText(“This is address .”);
$gm->SetInfoWindowText(“Anil Labs – http://www.anil2u.info”);
echo $gm->GmapsKey();
echo $gm->MapHolder();
echo $gm->InitJs();
echo [...]
Comments