39,323 Topics

Member Avatar for
Member Avatar for ak47carbon

i make a website in php ,in whichi give topic on topic user give comment , problem is that when user give comment ,after giving comment when we refresh the page , the browser ask a question resend and cancel in dialogue box sir plz tell me how can i …

Member Avatar for Biiim
0
201
Member Avatar for ebanbury

Hi I'm still retrospectively trying to edit all my interactions with the database to be in prepared statements. I'm having an issue with my registration form, with the passing of my $password and $activationKey. The code is: // $stmnt1 = $dbc->stmt_init(); $query = "INSERT INTO xxxxxxxxxxxxxxx VALUES (?,?,?,?,NOW(),?,?,?,?,?,?,?,?,?,?,?,?,?,?,'$activationKey')"; $stmnt = …

Member Avatar for cereal
0
81
Member Avatar for mrcniceguy

basically i am checking if i am in the same url as the page and i want to refresh the page only once,but whenever i try it keep refreshing infinitively place='/development/petersburg'; var pathname=window.location.pathname; if((pathname==place)){ window.location.reload();//reload the page } help!! how can i limit this page to refresh only once if …

Member Avatar for mrcniceguy
0
2K
Member Avatar for Poonam Jadav

Hello sir/mam `Inline Code Example Here` i am a student and working on php and javascript but i have a very little knowledge of javascript i am stcuk in my project i want to calculate total of two variables which are defined in two different javascript function here is my …

Member Avatar for Biiim
0
105
Member Avatar for 3tplus

Hi, How can i create a link in my PHP code (index.php) that when a user click on that link it will: 1. call doSomething() function within index.php 2. then call Myhtml.html Thanks for your help

Member Avatar for Biiim
0
410
Member Avatar for ebanbury

Hi I am a bit stuck on how to close a security issue. Basically if someone is looking at their profile and wants to edit it the URL will show the id of the user. Currently anyone can just change that number and have access to viewing and changing another …

Member Avatar for Biiim
0
4K
Member Avatar for Madriganoh

REFERENCED WITH confic.php for connecting the database. $link = mysql_connect(DB_HOST, DB_USER, DB_PASSWORD); if(!$link) { die('Failed to connect to server: ' . mysql_error()); } //Select database $db = mysql_select_db(DB_DATABASE); if(!$db) { die("Unable to select database"); } //Function to sanitize values received from the form. Prevents SQL injection function clean($str) { $str …

Member Avatar for pritaeas
0
232
Member Avatar for stereoworld

Ahoy, I'm having a bit of trouble executing a stored procedure using PHP's SQLSRV package thing. It's pretty much just a simple select query, with the parameters being passed through a php (it's from a property search). SqlSrv is a tough nut to crack as docuemtnation is either non existent, …

Member Avatar for stereoworld
0
5K
Member Avatar for HasNor

Hi guys, Here I got a problem that my session expired is not secure I think.. I use this code, but user can click button back and go to previous page. Means session not destroy.. May I know why its happen. Within 15 min it will be logout but user …

Member Avatar for HasNor
0
168
Member Avatar for mtho

Hi Guys Im kind of new to this and i hope i will explain myself enough for you to understand my question. I have a little dynamic blog. I have a form (called add_post.php)i use to insert my articles (blog_enrty). Unfortunately i get an error saying "you do not have …

Member Avatar for antonioazevedo
0
129
Member Avatar for laura301019

Hi i was just wondering if anyone knew how to generate a drop down menu with sql. The section of code i have that has to be changed is <div> <span class="bold">Choose a lecturer:</span><br> <?php // note how the keyword "distinct" in the following query prevents duplicate values from being …

Member Avatar for diafol
0
108
Member Avatar for DaveyMoyes

Hi All, I have the following scrip that uploads a image to a destination folder on my server. What I am trying to do is "rename" the uploaded file and update the link in the back end database. The file uploads and stores in the correct folder, but what it …

Member Avatar for cereal
0
181
Member Avatar for spivey

I have a php foreach loop that displays a span element with a name in it, and an associated input field for each item in the array being iterated through. There is an onclick so that the value is passed to the associated input field: <span onclick="setAuthor(this)">name</span> Here is the …

Member Avatar for CoursesWeb
0
169
Member Avatar for lastgame2007

//time Am $a=$_POST[am]; $a1=$_POST[am_min]; $tmeAm=$a.':'.$a1; //time AM //time Pm $p=$_POST['pm']; $p5=$_POST['pm_mins']; $s=':'; $times=$p.':'.$p5; $ttime=$tmeAm.'-'.$times; //days $days=$_POST['days']; for($i=0;$i<count($days);$i++) $dd=$days[$i]; mysql_query("insert into tc_handle set sid='$_POST[ass]', sub_id='$_POST[lvl]', secid='$_POST[secs]', section='$g_sec[name]', year='$g_sub[year]', code='$g_sub[code]', date='$cur', acad_id='$now[acad_id]', time='$ttime',room='$_POST[rm]', ** days='$dd'-------------------------- having problem here, it only saves the last checkbox in my form, why is it???** ")or die …

Member Avatar for blocblue
0
99
Member Avatar for djexploit

Hi, i have i site where you can get points when you click on an image. I need to have a code that automatically gives points to the user that clicks on the image. this is the mysql query to give the points. mysql_query("UPDATE `members` SET `points` = '$points1' WHERE …

Member Avatar for CoursesWeb
0
116
Member Avatar for khajvah

Hello people, I am future web designer and want to learn PHP and javascript, i already know a little javasctipt but i have never touched PHP. I need 2 books: one for PHP and one for javascript, money is not a problem... I saw some books "PRO JS for web …

Member Avatar for khajvah
0
289
Member Avatar for ratazoit

#I need a php script that fetches a registered users info from the Mysql database and prints them on the page when a user visits his/hers profile page via a link showing his name, like facebook # * Heres the code that id like to show as the profile pag …

Member Avatar for Dani
0
702
Member Avatar for vaanipala

Hi, How do I prevent my user from submitting an empty form? When I do that, I'm getting a HTTP 404 not found error in IE and a blank page in Firefox. None of the validation errors are showing up. I even tried putting an else stmt in the StudentsController's …

Member Avatar for trav04
0
220
Member Avatar for a_salted_peanut

Hi all If anyone can provide some light on this one it would be very much appreciated! I have spent a few hours on this one trying to figure out why, when i try and submit a form via HTML to a PHP script it seems to fail and not …

Member Avatar for a_salted_peanut
0
163
Member Avatar for ostrados

Hi all, hey guys could you please help me in this issue: i get warning message whenever i try to run my login form Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'root'@'localhost' (using password: YES) in C:\xampp\htdocs\db.php on line 10 unable to connect to the database i am using xampp, …

Member Avatar for ostrados
0
994
Member Avatar for heshanm

Hi all, I have small problem regarding my student registration form. When i enter data and submit always below message is displayed irrespective of whether the admission_id is exist or not. "Admission numberThis student has been already entered to the system" **newStudentRegistrationForm.php** <form name="form1" method="post" action="newStudentRegistrationFormvalidation.php"> <?PHP $con=mysql_connect("localhost","root",""); mysql_select_db("student_management",$con); ?> …

Member Avatar for IIM
0
251
Member Avatar for dualzNZ

Hi all I have created a dynamic signatre system for my site and i would like to add the members avatar based off sig.php?username=USERNAME but when i output the file the avatar is massive how can i resize the image from say 100 x 80 to likes of 24 x …

Member Avatar for dualzNZ
0
111
Member Avatar for drogba123

Hi guys, How can i read a specific line of the text file for example: user1 : johnson number of parts1 : 5 number of parts2 : 10 user2 : andy number of parts1 : 10 number of parts2 : 10 and i want to get the total number of …

Member Avatar for veedeoo
0
100
Member Avatar for saadi06

Hi, I am facing a problem in transferring session.I am developing a website and I want to integrate a forum in the website.I need to take the session of the user from my website to the forum. Is there any way of transferring my session values to the forum. Thanks …

Member Avatar for veedeoo
0
465
Member Avatar for programmer12

Hi, I am trying to setup a cron job on my web hosting server. I want the php file to run every 15mins. Can some one tell me if I set it up right or not? Also, since there time is 3 hours behind me I want to use my …

Member Avatar for programmer12
0
383
Member Avatar for BenzZz

Hi, I've been reading into testing my PHP code particularly unit testing using PHPUnit. The problem I have is that most of my code is procedural with not even many functions. I have read that unit testing is more suitable for OO PHP however i have seen that many people …

Member Avatar for BenzZz
0
502
Member Avatar for dyingatmidnight

Hello all, so I was tasked with looking into a way to rewrite our dynamic url's to something more user and seo friendly. I have absolutely no exprience in this area so it's been a lot of googling and trial and error. However; I've reached something of a wall in …

Member Avatar for blocblue
0
163
Member Avatar for samidha

I am a new user in PHP and currently developing a blogging web-site using PHP. I have designed a simple design of Create Blog page using HTML syntaxs, created database fields in MySQL as 1) Blog-Id 2) User-Id 3) Blog-title 4) Blog-text. Now if I am supposed to give interface …

Member Avatar for pritaeas
0
217
Member Avatar for DaveyMoyes

Hi everyone, I need a wee bit of help with the following. I am calling all country names from a db table and echo-ing out each country name in a list format. $query = "select * from countries order by Country Desc"; $result = mysql_query($query) or die(mysql_error()); while($row = mysql_fetch_array($result)){ …

Member Avatar for DaveyMoyes
0
449
Member Avatar for imolorhe

Please what is the best programming language and IDE that can be used in the development of WML web applications for mobile phones?

Member Avatar for peter_budo
0
65

The End.