Quantcast
Channel: PHP Freaks: PHP Help
Browsing all 13200 articles
Browse latest View live

Retrieve table data based on a single variable

i have a variable that is passed from a select list, the value of the select list is a stockID <?php echo $XCart_StockID = ${$XCName}["contents"][0][$XCart__i]; ?> this is constructed from an...

View Article


Probelm with exploded array.

I have retrived a set of numbers from a device, I divided it into two parts and compared if that exist in a table. When i gave a random array it worked properly. Below I give the code. <?php...

View Article


Image may be NSFW.
Clik here to view.

SQL Unknown column 'title' in 'field list'

Hi guys, I'm kinda new to PHP, and I started with developing a site. Now I've a piece of code (check below), it is suppost to edit a page in the database, but the output is "Error updating database1:...

View Article

Creating dropdown inside <?php ?>

Hello. I have a little complex code for a navigation menu. I want to add a dropdown to a <li> tag but it doesn't work. Heres the code <div id="topbar" class="fadeInOnLoad"> <div...

View Article

Html/PHP contact form checkboxes array

Hi guys,   I'm quite new to php - I've made forms before but not come across having to make checkbox options appear in email.   I've searched the forum and have found similar posts but none of the...

View Article


how to display my success message

Hey All,   I am having some issues my data gets added to the database ok but since I am using a header redirection (to clear the $_post variable) my success message is not displayed or my error if...

View Article

Browser isn't rendering ob_flush output immediately

I'm writing a file upload script using the iframe method. At the backend, post file upload, the script does a few more things. So I'm flushing output to the browser (which goes to the iframe) as soon...

View Article

wrong syntax in line of code

Can someone tell me the syntax error in this line of PHP code action="http://example.com" '/wp-login.php?action=postpass' method="post"

View Article


preventing PHP page from outputting text (part of Ajax app)

Here is a segment of code that I'm using in a PHP script, which is called as part of an AJAX HTTP Request:   <?php         $result = $user_conn->execQuery($sql_query);          while ($row =...

View Article


header(); presents infinite loop in IE, works on other browsers?

OK, I'll keep this short n sweet.   Goal:   If a specific variable is declared in the URL, assign it to a session and refresh the page without the variable. Here's my code:...

View Article

Image may be NSFW.
Clik here to view.

PHP Parse error: syntax error, unexpected T_VARIABLE

This is the only error I get.   PHP Parse error:  syntax error, unexpected T_VARIABLE  on line 15    Line 14: $myfile = "s_vcs.txt" Line 15: $fh = fopen($myfile, “a+”) or die("Couldn't open $myfile");...

View Article

Warning: Header may not contain more than a single header, new line detected...

Getting this error: Warning: Header may not contain more than a single header, new line detected in While using POST and GET between variabales:   <?php     $name = $_POST["Name"];     $email =...

View Article

check if record exists

I am the newest of new to PHP and am just starting to code my first project.   I have a database (db_code) with a single table (tbl_code) with 1000 records of 8 digits. something like DHYHGTYF,...

View Article


where is the error

Hi: I have an error that will be very basic, but I don´t see it...   I have this first php: <?php session_start(); require ("connecting.php"); require ("searchprofile.php"); connect();...

View Article

PHP, MySqli comparing and displaying results

I’m curious as to what other developers do to compare Database results for web display.   Simple example:  - select sum of all my expenses, sum of all my payments received;   - Display a table with the...

View Article


if... else... & elseif

Hi, since learning PHP i've come across this and i'm a little confused. Was wondering if anyone could shed some light on it.   I'm more than familiar with IF statements from C++. However i'm confused...

View Article

Sending emails in a foreach loop. Best way to do this?

Would it be better not to mail and loop or to create a BCC list by imploding the recipients list and send them out in one single blast?

View Article


Transactions works but query doesn't

Hi all,   Here's my coding issue: I have a transaction script that is supposed to insert into a sold_items and then update the products table--this works perfectly. However, I want to introduce a third...

View Article

how to process form in better way

i already completed this part,.   form1.html data gets entered and processed with form1.php. Data is passed with ajax. This form has only one button to submit form.   Now i have form2.html which is...

View Article

encoding url not working

I'm trying to encode a url like this, $code = '2'; header('Location: http://www.whatever.com/page.php?='.urlencode($code).''); exit(); and then decoding it on the page.php page like this, $url =...

View Article
Browsing all 13200 articles
Browse latest View live