php

how can i stop a php page from loading when its taking too long

i have a php page which auto refreshes itself after 10 seconds. Some time the page takes too long to load as its fetching data from external urls . How can i stop execution of the script after 10 seconds and then reload the page. ...

PHP won't echo out the $_POST ...

Hi guys, got a small problem, this code <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post"> <?php ... echo '<input name="textfield" type="text" id="textfield" value="Roger" />'; echo 'Hello, '.$_POST['textfield'].'<br>'; ... ?></p> </form> should echo out "Hello, Roger", as roger is the default value, yet it gives out on...

how to get store information in magento?

How to get active store information like store name,and line number etc in magento? ...

Data pagination with "saved" search

I'm creating a page that's a search result... When you're viewing one of the results, at the bottom of the page, I need to insert "Next result" and "Previous result" links, like a pagination... But from [I think] a saved search, right? How you people would do this? Obs.: I'll use CakePHP (PHP) and MySQL -- Update: The problem is not...

Javascript Alert Return value / Event

Hey, The question is pretty simple, but i'm not the big AJAX/JS coder, so I have no clue if it's possible. Is there any way that I can check whether or not an alert() was executed on a remote site? Like if I inputted an alert("Welcome to this site"); through a get variable, is there any way to check if it that alert() was actually exec...

Joomla error 500

hi, i have a joomla webshop with IIS 7 and PHP / MySQL. I ever get the rrror 500, problems with FastCGI. I google around 20 hours and tried everything, really everything but I have NO idea what to do. I will pay 100€ by paypal for a right answer. ...

Running Mantis on MS SQL Server

As a part of the technology standardization in the organization I work at, we're moving from MySQL and Linux to MS SQL Server and Windows. One of the PHP-based applications that we use is Mantis, a bug tracking system available at http://www.mantisbt.org Has anyone had any luck getting Mantis to work completely with MS SQL Server? I've ...

Security of Flex for payment website

So, it's been about 3 years since I wrote and went live with my company's main internet facing website. Originally written in php, I've since just been making minor changes here and there to progress the site as we've needed to. I've wanted to rewrite it from the ground up in the last year or so and now, we want to add some major featur...

how to place the value for text area

Hi while I am performing the edit function .. i have a textarea where i type some text and submit <tr align="left"> <td class="table_label">Reason </td> <td><textarea cols="17" class="text_box_login_14_width_150" size="5" name="txtReason" id="txtReason"></textarea></td> </tr> when i submit i mu...

FacebookRestClientException: A session key is required for calling this method in

I have a app, that is used in the fanpage, so basically I am showing up the user request/invite form, after submission which refers to my server and I get friends ids(from $_POST) and info about user who sent invite, to get user info I am using $user = $this->_facebook->api_client->users_getLoggedInUser(); $dataToRetrive = array(.....

Jquery Ajax PHP - Pass values from PHP script into Ajax Success function?

I have a form that is submitted via Ajax to a PHP script. Inside the PHP script I do a few checks for swear words. How would I pass a 'yes' or a 'no' back to jquery from the PHP script so I can display some feedback to the user on the front end? In other words, a 'Thank you', or a 'Don't Swear!' Thanks ...

mysql to excel generation using php

<?php // DB Connection here mysql_connect("localhost","root",""); mysql_select_db("hitnrunf_db"); $select = "SELECT * FROM jos_users "; $export = mysql_query ( $select ) or die ( "Sql error : " . mysql_error( ) ); $fields = mysql_num_fields ( $export ); for ( $i = 0; $i < $fields; $i++ ) { $header .= mysql_field_name( $export ,...

Warning: PDOStatement::execute(): SQLSTATE[HY093]: Invalid parameter number: number of bound variables does not match number of tokens in ...

Hi, I'm working with PHP PDO and I have the following problem: Warning: PDOStatement::execute(): SQLSTATE[HY093]: Invalid parameter number: number of bound variables does not match number of tokens in /var/www/site/classes/enterprise.php on line 63 Here is my code: public function getCompaniesByCity(City $city, $options = null) {...

can I use a number of "facebook likes" in php?

I am using facebook like in my site, and my php script need to know how many people like every page. For example I want to use in php echo $likes; where $likes is a number of likes. Is it possible to do? ...

PHP - How to combine / merge multiple pdf's

Hi, I have some pdf documents on a linux server that I want to combine together to form one document using PHP 5? Does anyone know if this can be done? Thanks ...

Comment associative array in PHP Documentor

Hey Guys, i hope someone can help me out on this one here. I use several associative arrays in my php application and i'm using php documentor to comment my sources. I never really did specified comments for the arrays in an array, but now i need to do that and dont know how. $array = array('id' => 'test', 'class' => 'tester', 'options'...

download file, without saving in server

Hi, Or possible for users to download the file without saving it on the server? I am getting data from the database, and I want to save them .doc (MS Word) file. if(isset($_POST['save'])) { $file = "new_file2.doc"; $stringData = "Text text text text...."; //This data put in new Word file $fh = fopen($file, 'w'); fwrite($fh, $st...

Ajax call not working...

Hi, I have a form that submits to a PHP script with Jquery and Ajax. The PHP script returns some XML. For some reason the Ajax success function is not firing, and the error ones is. Can anybody see where I'm going wrong? My Jquery is as follows $('#submit-excuse').submit(function (event) { event.preventDefault(); ws_ur...

How can I send GET data to multiple URLs at the same time using cURL?

My apologies, I've actually asked this question multiple times, but never quite understood the answers. Here is my current code: while($resultSet = mysql_fetch_array($SQL)){ $ch = curl_init($resultSet['url'] . $fullcurl); //load the urls and send GET data curl_setopt($ch, CURLOPT_TIMEOUT, 2); //Only lo...

PHP and MySQL SELECT problem.

Trying to check if a name is already stored in the database from the login user. The name is a set of dynamic arrays entered by the user threw a set of dynamic form fields added by the user. Can some show me how to check and see if the name is already entered by the login user? I know my code can't be right. Thanks! MySQL code. SELECT ...