39,323 Topics
| |
| |
I'm stuck in a problem.. I want to use two combo let Country and City, where City list depends on the Country combo, How can I don do it with HTML and PHP only? Thanks. | |
I have two separate pages. One page I'm using some UPDATE queries and the second page uses an INSERT query. Neither are updating my database. I can read the database from php, but not update it. Is my syntax correct? I know I can make it more efficiant, but I … | |
Hi Guys I am new to PHP and slowly learning. I have a piece of code that I need some help with. I am trying to take user input and use it to query data from a table in MYSQL. I know all my connections are working because I can … | |
hey guys I just implemented some AJAX which calls a PHP function and gets random data from a database, and displays it accordingly. Problem is, I had the link which you click the randomly change the information on screen counting how many times it'd been clicked with a session. And … | |
My code is suppose to crawl web pages, index the links, then crawl those web pages and on and on again! But it won't work? I get no errors what is wrong? I think it gets into the foreach but doesn't make it to the $DCheck if statement! [CODE]<?php if(empty($_SESSION['page'])) … | |
Hey Guys, Struggling a bit here trying to get my head around something. I'm not a PHP expert, but I feel I've come a long way in the 6 months or so I've been learning it. Anyway, I thought I would pluck up the courage to build my own custom … | |
Hi Guys The following question is related to the following url: [URL="http://www.sheltonwebdevelopment.com/blog/2010/03/01/calculating-totals-with-jquery/"]http://www.sheltonwebdevelopment.com/blog/2010/03/01/calculating-totals-with-jquery/[/URL] I have just a small question now regarding the dropdown. I am sure its related to an 'id'. Here is my script: [CODE] 1. <td><?php echo "<select name=\"field1\" class=\"qty\" onchange=\"calcTotal();\">"; ?> 2. <?php 3. for($i=0;$i<=50;$i++){ 4. echo '<option … | |
Hello! I am trying to make this work. [CODE]//make user folder $userid = $_SESSION['loginid']; $userdir = "./u/".$userid."/"; if (!is_dir($userdir)) { mkdir($userdir,0777); copy("/home/users/web/b681/ipg.xxxx/shack/u/index.php","/home/users/web/b681/ipg.xxxx/shack/u/".$userid."/index.php"); echo "Your directory was created. This is where all your files will be stored.<br>"; } else echo "";[/CODE] This part of the code is Ok but it does … | |
Hi there, I am having a Javascript problem and any help would be apprecated. I am trying to test the input for if length = 1 then add on a 0 as this would mean if the user wanted £1.20 if would come out as £1.20 and not £1.2 as … | |
I am not able to open the ex.php page I created in my local host. I recently installed Apache 2.2 and PHP. I configured httpd, virtualhost etc as mentioned in many tutorials. ([URL="http://webdevcodex.com/screencast-installing-apache2-php5-mysql5-phpmyadmin3-windows-7-vista/"]http://webdevcodex.com/screencast-installing-apache2-php5-mysql5-phpmyadmin3-windows-7-vista/[/URL]) Whenever I tyoe [url]http://localhost[/url], the browser tends to download the indox.php file. the file is nothing but … | |
Hello . I'm not sure what is wrong in my code. I'm trying to expand table row to see more details from mysql query . The idea is to click 'show / hide ' link and on that onclick event the row below need to be expanded.Here is my code … | |
I want to make css manager for my site like wordpress's css manager. I want to open css file in textarea so I can edit it than after pressing submit button, changes in css file should be saved. Please help me. Sorry for my bad english. | |
hey people . i want to create a a posting system , not the usual one , i want to create a posting system like the wordpress one , it should provide add image and fonts and sizes and it automatically add new lines , i shearched in google for … | |
i'm use smarty 3 and write [CODE]$smarty = new Smarty(); $smarty->config_dir='./smarty/sconfigs/'; $smarty->template_dir='./templates/new/'; $smarty->compile_dir='./smarty/stemplates_c/'; $smarty->cache_dir='./smarty/scache/'; if(!$smarty->isCached('index.tpl','default')) { $smarty->assign("u",refresh_user_info(),true); } $smarty->display('index.tpl','default'); [/CODE] but {$u} is missing when i add if($smarty->isCached help please! | |
So basically what im trying to do is pass a variable from a JS function to PHP variable. Currently the onClick code is: [code] <?php include('onload.php'); ?> <body> <br /><br /><br /><br /> <center><font color="black" size=20><a style="text-decoration:none" href="#" onClick="showpopupshare()"> [/code] ShowpopupShare(): [code] function showpopupshare() { document.getElementById('mmpopup').style.display='block'; document.getElementById('mmpopup1').style.display='block'; window.setTimeout("StartTheTimer()",30000); } [/code] … | |
Hello all: I have a small script that will present options to a user, and from those options will export data into an Excel spreadsheet. This seems to work correctly, but the problem is that the user interface page does not get updated after the download. Here is an example: … | |
| I have created my personal login system. I am kinda newbee here. When user log in it creates cookie as 'user'. I've seen some sites to which creates password cookies too. So i need to verify both the cookies in mysql database every time with the every page loads? And … |
When I execute the script it returns no info just blanks: First Name : Last Name : Email : What is wrong with my script??? I have tried using the "while" function but I do not need it for what I am doing. [code] <?php require_once('connectvars.php'); $search = $_GET['search']; //connect … | |
I've been trying to get this code to work for hours can anyone spot the mistake i made? its a code to edit the contents of a database field calling it by its primary key. my error code is Parse error: syntax error, unexpected T_VARIABLE in E:\xampp\htdocs\php\databaseview\records.php on line 103 … | |
Hi! I am getting message #1052 - Column 'userlevel' in where clause is ambiguous while running following query: [CODE]<?PHP $query=mysql_query("SELECT mssgs.start_date, mssgs.task, mssgs.status, mssgs.timestamp, mssgs.due_on, mssgs.id, users.fname FROM mssgs INNER JOIN users ON mssgs.uid=users.uid AND mssgs.userlevel=users.userlevel WHERE status=0 AND userlevel=1 OR userlevel=3"); if(mysql_num_rows($query) > 0) { while($row=mysql_fetch_array($query)) { if($row!=0) { … | |
Hi, guys I made a web application and run in local host in Mac, but the problem is that when I copy that folder and paste in my system (xp) then it is not working, I don't know what is the problem ....??? can any buddy know this problem then … | |
Hello, I am trying to get the MySQL id field to auto update itself when an item is deleted. However the below doesnt work. When a user searches by name, then I need to grab the id of that name before I delete it and minus 1. [CODE]$name = $_POST['name']; … | |
The below code works well in my localhost, but gives an error whenever I upload it to my hosting server! :?: Somebody please suggest me what to do ??? [B]Here is the code:[/B] [CODE]<?php error_reporting(E_ALL); ini_set('display_errors',1); require('Connections/cn.php'); if(isset($_POST['modify_m']) && $_POST['modify_m']=="Update") { //Update image $file_name= $_FILES["file_m"]["name"]; $file_type= $_FILES["file_m"]["type"]; $file_size= $_FILES["file_m"]["size"]; $file_temp= … | |
For example here is some code..... [CODE] preg_match_all("/<a(?:[^>]*)href=\"([^\"]*)\"(?:[^>]*)>(?:[^<]*)<\/a>/is", $stripped_file, $matches);[/CODE] What I don't get is all of those special characters? (?:[^>]*) How can I do this with the h1 tag, h2 tag, and h3 tag? | |
Hello, I am having a company here with foreign retailing. I have to ship packages abroad. Due to workload I cannot remember what parcels I have sent. I had a script which I used to print Labels to print. But now, what I want is, while the script prints a … | |
I have already completed a form registry and works!!. Well nearly I have an error which displays this [CODE]Warning: extract() expects parameter 1 to be array, null given [/CODE] Heres the code [CODE]<?php /* Program: Login.php * Desc: Login program for the Members Only section of * the pet store. … | |
Hi, I have the code below for a login script. I not finished it yet and i moved from Dreamweaver to Netbeans a while ago and all my code has lost it's indentation and formatting. I am missing some curly bracelets i am sure of it but cannot find where … | |
i am trying to register 2 sessions. one is supposed to get the id of the user logging in, the other is supposed to get the persons username. here is the login page: [CODE]<?php session_start(); include "dbconnect.php"; $myusername=$_POST['user']; $mypassword=$_POST['pass']; $myusername = stripslashes($myusername); $mypassword = stripslashes($mypassword); $myusername = mysql_real_escape_string($myusername); $mypassword = … | |
This is a very simple bbcode example to use on a forum or your pages. Add this to a function page and make sure the function is required on the page you want to on. ENJOY!! :D |
The End.