39,402 Topics
![]() | |
Hey all, I found this script that i'm using to read a directory, show all the pdf files in it, then be able to click on one of the pdf files displayed and open the pdf. So far i can show the pdfs in the directory, but when I click … | |
I've got a problem with a web application that runs slow when called by JQuery? Below I will be summarising the structure of the application, but just to say that it is hanging inconsistently and unpredictably as if the (dedicated) webserver runs out of memory or too many database connections … | |
Hello! I am a n00b to both PHP and Javascript, so please bear with me... I have a form and I use Javascript to validate the form. If there is an error on the for it displays the appropriate alert. The problem I have is when I click "OK" on … | |
I'm somewhat new to PHP. I'm not sure how to point to the root of my web site in a function. I was using $_SERVER["DOCUMENT_ROOT"], but when I use it in my function it comes back: "http://mywebsite.com/var/www/html/mypath" Note - this is in the HTML - other parts of the function … ![]() | |
Hi, I use PHP and have a question. As cookies and sessions have their pros and cons, I don’t know which one is better for shopping card. If I use cookie then user my block it. Therefore, my e-commerce web site won’t serve the purposes. If I use session then … | |
Hi all! I created a form for a website I'm building for a friend; and he wants to be able to have the form information submitted to him via email. The problem is that when the information is submitted, the items are coming up with the names, not the label … | |
I summarised my problem by a simple example,anyone plzz ans this...then I will be able to understand my problem.......: Suppose in a database named "DATABASE"..there is a table called "XYZ"..it has 4 rows named "T1,T2,T3,T4"..one primary key named "T_id"..now what I want that to access this same table via different … | |
i need to retrieve information about customer order when the user submit their name this the code for first page [code=php] <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title>Prac 3 Task 4</title> </head> <body> <?php $conn = odbc_connect("warehouse","IWSDStudent","assign2"); $sql = "SELECT … | |
Hi, I am trying to upload my images using my ftp folder by php code.Begining it was worked very fine.recently i shifted my domain from one server to another one server now if i am trying upload any images it storing path into database and its not uploading that image … | |
Hi, Don't know why but i always seem to mess my, mysql querys up somewhere, usually silly things like quotes etc. The code below, i have a problem. Basically when user gets an email they click the link and they are taken to a page where they can change there … | |
i have listbox 1 which displays status , based on selection of status listbox 2 displays usernames. and based on username selected the textbox displays the email id. its working fine till displaying user names in listbox 2 based on selected of status in listbox. but its not displaying the … | |
Hellow all, I want to ask a question about making quiz script with PHP if I have an array like this : [ICODE]$pet = array("angora","bird","chipmunk","dinosaurus","eagle","finch");[/ICODE] and I want to make a question like this [B]Do you have angora ? oYes oNO [COLOR="Red"]|submit|[/COLOR][/B] when user click "submit" button, then it will … | |
Hi, I want to Compare & count elements in array?? suppose in my array $arr={140,123,34,140,23,123,140,140,123} I want to display like 140 - 4 ( comes in array 4 times) 123 - 3 34 - 1 23 -1 How to do this?? | |
html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Validation Page</title> </head> <body onload="document.validate.name.focus();"> <div align="center" id="validate"> <form action="validate.php" method="post" name="validate" runat="server" title="This a validation form" > <table width="200" border="1"> <tr> <th scope="row">User Name </th> <td><label> <input name="name" type="text" id="name" /> </label></td> </tr> <tr> <th scope="row">Password</th> <td><label> <input name="psw" type="password" id="psw" … | |
hi there! im having a problem with making an order form. i want to display the products from a database and beside the product names, the customer could enter the quantity he wants to order. when the submit button is clicked, there comes the error. im a newbie in php … | |
:?: HI Guys...:'( can anyone of you knows how to make a quick qoutations.. By the way i'm mark a newbie in programming..and here's my problem.. i would like to create a quick quote for my project that can solve a simple mathematical quotations..like for example when you enter your … | |
Hi, I get an error when i try to echo my cookie. [inlinecode]Notice: unserialize() [function.unserialize]: Error at offset 0 of 12 bytes in...[/inlinecode] I cannot find a solution. Help please. Thanks [code] class MyCookie { public function __construct($cookieName, $sessionId) { if(! isset($_COOKIE[$cookieName])) { $cookieValue["SESSION"] = $sessionId; setcookie($cookieName, $cookieValue, time()+60*60*24*7); } … | |
I have php 4.4 version i am getting a strange error here. [CODE] echo strtotime("2009-04-24T20:00:05.000Z"); [/CODE] It is giving result as -1 What is the problem and how to overcome this. I dont have an option for php upgradation. | |
Does anyone have any ideas on how to change how submit buttons can be changed from the default? I think it is a real shortcoming of HTML that onmouseup and onmousedown etc are not permitted with <input type='submit'.... I just feel there must be some clever way using javascript or … | |
If you are trying to do a page, or section of news that only shows a certain length of characters, and then has a link for Read Full Story, or more..., etc the following code is just what you need: [php] $longtext = "Full text string to be manipulated"; // … | |
Hi, As you can probably tell by now my knoweldge of MySQL is not very good. I basically have two tables. One called [B]userinformation[/B] and another called [B]profiles[/B] My userinformation table is like this: [CODE]CREATE TABLE `userinformation` ( `id` int(11) NOT NULL auto_increment, `status` varchar(20) NOT NULL, `username` varchar(20) NOT … | |
to connect/close connection my dbs i use the below include files [B]config.php[/B] [CODE]<?php // Admin Database Properties $admindbhost = 'localhost'; $admindbuser = 'user_default'; $admindbpass = '************'; $admindbname = 'db_admin'; // Default Database Properties $defaultdbhost = 'localhost'; $defaultdbuser = 'user_default'; $defaultdbpass = '************'; $defaultdbname = 'db_default'; ?>[/CODE] [B]opendb.php[/B] [CODE]<?php // Admin … | |
dear all, I would like to know how to structure and SQL query to query between months ranges Something along the lines of: SELECT * FROM table WHERE datetime BETWEEN xx/xx/xx AND xx/xx/xx I have a table with the following date field entry named datetime: 07-05-2009 Which I am assuming … | |
I have the following problem is that regardless of the error it only seens to return the value of $error==4?? there are multiple files being uploaded but i only want to retrn 1 message error 4 if no files have been uploaded and error 2 if a file is more … | |
how i use apache server, php, and MySql .Tell me the procedure for installation of Apache server, PHP, and MySql | |
Hello everybody, I have this text file, and when I import them into mysql through phpMyAdmin, everything is ok, but the persian (Farsi) not shown correctly, also I use ' utf8_persian_ci ' collation, can anyone kindly plz convert this file into MySQL that farsi data shows correctly too? NOTE: farsi … | |
Hi When i use time() function in php,i got the value as follows, [B] 1242104663[/B] i retrieved thelogin time for ,but i want to get the current system time in hours,mins ,seconds Regards, Vidhya | |
Hi I am creating session for my website,i want to expire the session after particular time for the user logged in,i want to retrieve current time in PHP,i used a time() function in php to get current time,but i got sequence of number.can oyu help me how to get current … | |
i have a function like i have quote issue with the function. I have to use this object in javascript code due to some reasons i cant use double quotes two times. i have to use single quotes around parameter as well. what should i do. please suggest. [CODE] <script … | |
Hi all! So I've been reading about the "FOR XML AUTO" function which sounds great, but it hasn't been working when I try it in phpmyadmin. I get an error in the area of "FOR XML AUTO", I know SimpleXML is disabled on my package but would that be why … | |
Hi, I am trying to display the users email address when they login to there account on there profile page.. I have successfully done this for there username as i use $_COOKIE to display the users name with the DB. Problem is i am not sure how to do it … | |
is there any way to get the name before i post, i want to get the name before i post becuase i want to delete a php file and create a new one instead of it [CODE]if(isset($_GET['id'])) { $query = "SELECT id, name, title, description, keywords, content, skin ". "FROM … | |
Dear php pro guys i need your help please; i have 3 files; index.php login.php and member.php my major problem i cant prevent the link to be copied after logging in in php4 ---file:memeber.php--- if ($_SESSION["login"] !=1 -- it works great when the user log in and link can not … | |
I have a script which upload image to the server and resize them when uploading)) the script give a max width=200px also max height=200px))for i uploaded image.. i would like if some one can help me modify it,in such away that if Only width must be Max=200px but for height … | |
I have three dbase tables: Project: Building a set of tables to record customer information, record selected uses of transportation, record the points earned from using certain types of transportation, record the total points in a database table. [CODE]Currently, these are the tables: Code: TEAM teamID teamName LIVE DATA: Live … | |
hello i am wondering how i can go about making links similar myspace where i can give users a custom link where the do not have to type in my whole dynamic link like [url]www.example.com/index?action=profile&fid=id&token=key[/url] instead i want it to look like this [url]www.example.com/USERS_CUSTOM_URL[/url] that will forward them to the … | |
have this script [CODE]$idhandle = fopen($filename, 'r+') or die("can't open file"); $id = "<?php \$lastid = \"$lastid\"; ?>"; fwrite($idhandle, $id); fclose($idhandle);[/CODE] trying to write "<?php \$lastid = \"$lastid\"; ?>"; in the first line of the file but what is happening is its deleting some of my code in the file. … | |
Hi i am doing a project for college, and i choose car rental not knowing its trickier as i thought. Im using xampp and oscommerce, and well..PHP. i have almost everything done apart from the calendar where users can choose the dates of when they want to rent the car. … | |
i am on my try to develop quiz management system with administrator control(php +mysql). administrator must give no.of questions for the quiz (contestants will have to attempt all the questions in the database). i want to know is it possible to show each question in different pages.can anyone help me … ![]() | |
Hello Gang - First of all thanks for taking time to read this... I need some direction. I have background in HTML and Javascript. I am okay with CSS. BUT I am hoping to design a site similar to Urbanspoon.com and I need to know what programs that would involve. … | |
Hi, I need to use mail function to send emails to the user provided e-mail address which he/she gave at the time of registration. Can any one please help me regarding this? Thanks | |
alright im having so problems with my floating divs containers i am using three columns in my html part of my website and i have a wrapper around the three columns known as page and the columns are float left in css so they can be perfect aligned left to … | |
Hi, Somebody please help me, i am going mad out of my mind, for the past 4 hours or so some silly little problem has ratteled my brain and i cannot fix it. Basically, user registers on site, they get there activation email, click on link and the below script … | |
so i have a page called addpages with the following [CODE] mysql_query("INSERT INTO pages (name, title, description, keywords, content, updated) VALUES('$name', '$title', '$description', '$keywords', '$content', '$updated' ) ") or die(mysql_error()); // Get Last ID $lastid = mysql_insert_id(); // Start Create php page file $filename = "$name.php"; $template = file_get_contents("templates/default.php"); $filehandle … ![]() | |
Hi! I have a free script from Scriptol which I use to display feeds content on my site. The script has a form where you can submit a feed url and it will display on the same page the feed rezults. The problems is: - I want to make it … | |
I have a fix code below [code=php] $values=array( "advertisement1" => 34, "advertisement2" => 45, "advertisement3" => 16, ); [/code] I want to take some information from my database and output the same way I have the code above but am getting an error. I am using [code=php]$sql = "SELECT advertisement.adver_name, … | |
Hi, I have tried to find out on this, but I cannot be sure. Anyone knows for certain fopen and file_get_contents (or any similar functions) will generate an entry in the target domain's website traffic stats? I know this could be traffic analyser specific, so for a start, will it … | |
My static variable got initialized [B]everytime[/B] the function is called. Here's my code(simplied), thanks. - [code]<script> function validate() { return true; } </script> <?php vote(); Function vote () { static $testvar = 1; echo $testvar; if ($testvar == 1) { $testvar++; echo $testvar; } } echo '<td><input type="image" width=50% src="pix/camera.gif" … | |
Hi, As i am new in OOP, i just want to ask those who are experts in OOP that can this my example be considered as OOP example? Thanks [code] dbprocess.class.php <?php class DBprocess { private $dbconn; private $db; public function __construct($host, $user, $username, $password, $database) { $this->dbconn=mysql_connect($host, $user, $username, … | |
[code=php]<? //Database Connection $dbcnx = @mysql_connect('localhost', 'Haresh', 'iwdpwd'); mysql_select_db('iwddb',$dbcnx); $memberidresult = @mysql_query('SELECT * FROM members'); //db hase only 2 fields, memberid & name while ($memberarray = mysql_fetch_array($memberidresult)) { $memberid = $memberarray['memberid']; echo '<p>The member id is ' . $memberid . '</p>'; $namelink = $memberarray['name']; echo '<p> <a href="http://www.xyz.com/x/?x=c&z=s&v=1801659&k=' . $memberid … |
The End.