Is there any extension that helps me to add a thumbnail manually to an article? Not those exts which do it on the fly using the first image in the article. I want to add it manually. Answer See related question. Look at there 2 components, you can achieve pretty much the same thing: K2 ZOO, from Yootheme I wa…
How to echo in PHP, HTML tags
I went through this before posting: How can I echo HTML in PHP? And I still couldn’t make it work. I’m trying to echo this: But I still can’t find a way to make the tags “” and ” disappear. What do I have to do? Answer Just put it in single quotes.
Curl request is failing on the SSL?
I have this code if(ereg(“^(https)”,$url)) curl_setopt($curl,CURLOPT_SSL_VERIFYPEER,false); // execute, and log the result to curl_put.log $result = curl_exec($curl); $error =…
php – Is strpos the fastest way to search for a string in a large body of text?
if (strpos(htmlentities($storage->getMessage($i)),’chocolate’)) Hi, I’m using gmail oauth access to find specific text strings in email addresses. Is there a way to find text instances quicker …
Make a HTTPS request through PHP and get response
I want to make HTTPS request through PHP to a server and get the response. something similar to this ruby code Thanks Answer this might work, give it a shot. $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); // Set so curl_exec returns the result instead of outputting it. curl_setopt($ch, CURLOPT_RETURN…
pdf download html2pdf
i am using html2pdf class to generate pdf. in my problem its generate pdf for the html code but it not give the dialog box option to download that pdf. plz help my cose is following. <?php …
Slow MySQL full text search
I’m using this query to perform a full text search on a MySQL database: The results are very relevant, but the search is really slow and is getting slower and slower as the tables grow. Table stats: questions – 400 records indexes PRIMARY BTREE – id BTREE – uniquecode BTREE – que…
Multiple $_POST on same page PHP
I have a question. Currently this form will be dynamically generated. Example, So whenever i press submit, it will take last value of form only. How do i make it take all $_POST? Thank you. Answer Give each input its own name or use: Then PHP will treat it like an array.
How do I use a class method as a callback function?
If I use array_walk inside a class function to call another function of the same class It gives me the following error – Warning: array_walk() [function.array-walk]: Unable to call test_print() – function does not exist in … So, how do I specify $this->test_print() while using array_walk(…
No xdebug in phpinfo()
I have added following lines into php.ini [XDebug] zend_extension = C:PROGRA~1PHP5extphp_xdebug-2.1.0-5.3-vc9.dll xdebug.remote_enable=on xdebug.remote_handler=dbgp xdebug.remote_host=localhost …