Tag Archives: XML

Php Interview Questions and Answers – Part 9

images




1- How can we know that a session is started or not? A session starts by session_start() function. This session_start() is always declared in header portion. it always declares first. then we write session_register(). 2- What are the differences between  mysql_fetch_array(),  mysql_fetch_object(),  mysql_fetch_row()? Answer 1: mysql_fetch_array() -> Fetch a result row as a combination of associative array and regular array. mysql_fetch_object() -> Fetch a result row as an object. mysql_fetch_row() -> Fetch a result set as a regular array(). Answer […]

Convert .xsd file into array in PHP

jpeg




As we know that PHP has no direct function to convert .xsd(XML Schema Definition) file into associative array like XML file. So you have to  first convert .xsd file into xml then finally parse xml file into associative array. Below are few easy steps to convert .xsd file into associative array.   $doc->preserveWhiteSpace = true; $doc->load(‘yourfile.xsd’); Step 2: Save .xsd file as an xml file. $doc->save(‘myxml.xml’); Step 3: Generate xml as a string and removed xsd prefixes. $myxmlfile = file_get_contents(‘myxml.xml’); […]

Can You Answer These 10 SEO Questions

Running businessman.




I’ve compiled a set of 10 useful SEO questionnaire to brush-up your SEO knowledge. Sometimes, instead of reading lengthy articles and spending hours together, a few well-structured questions can make you dig deeper into the topic. I’m sure – most of the answers you already know. Rate yourself by giving you “number of questions you have answered correctly out of 10.” For better results/knowledge don’t read the answer immediately. Read the question, think a bit, and match your guess by […]

Parse JSON, XML and HTML – jQuery

jquery-evnets




In this post, find out jQuery code on how to parse JSON, parse XML and parse HTML. If you are still using custom code for parsing any of these and making your life more miserable then stop doing it. Why? If you are not aware then here is a news for you that jQuery has inbuilt utility methods for each. Which are, parseJSON() parseXML() parseHTML() Using parseJSON() This method takes a well-formed JSON string and returns the resulting JavaScript object. […]

Migrate your Articles to Joomla 2.5 with J2XML

joomla2




Follow along as I migrate a site from Joomla 1.5 to Joomla 2.5. Although there is no all-in-one solution to migrate your site (and rightfully so, as Joomla 1.5 and 2.5 are completely different systems), there is a great tool out there for importing your content into 2.5. Content, as in your articles, categories, images and authors.J2XML is the perfect component for exporting and importing your content. Its actually two separate components. The process is simple. First install the J2XML Exporter on […]

Best Creative Uses for PHP

Best-Creative-Uses-PHP




If you are familiar with the basics of PHP, then you’re probably wondering how you can use it to make your website more appealing. The possibilities are endless, and you can write your own PHP scripts or implement widely available scripts from around the web. Let’s get started with 15 creative uses for PHP for your website! 1. E-Commerce E-commerce is one of the major uses for PHP. From a small business level to an enterprise level, businesses are always […]