39,323 Topics

Member Avatar for
Member Avatar for bjice

Hey i'm writing my own first full website with PHP and MySQL and i've come to a problem. I know i need to optimalize it with some fewer echo's and more elses, but this is what i have now and apart from the problem, it works. On the site at …

Member Avatar for bjice
0
367
Member Avatar for prad27

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at W:\www\prads_website\index.php:15) in W:\www\prads_website\inc\adminloginpage.php on line 2 Hi everyone, I am new to all this so I do apologise if ive made silly mistakes. I keep getting this message and ive banged my head searching through …

Member Avatar for prad27
0
145
Member Avatar for ayesha789

Hi I have a table which have 4 fields. How i can give rights via DB for update, Select, Delete and insert. For example User A only Update Field 1 User B only Update field 2 and select all fields. User C can delete field 3 records User D can …

Member Avatar for ayesha789
0
164
Member Avatar for daveroesch

I am new to PHP and I want to make it so every field is required to send the form. I've tried a few different ways but nothing seems to work. Below is the script with no required fields. Can anyone show me how this would be done? Thanks, Dave …

Member Avatar for metalix
0
1K
Member Avatar for Asimina

i have this php code below: i want to display users that are online . if they are not active the next 20 min then there name will not be displayed and there status will be turned OFF in th database table tng_users field status but i also want all …

Member Avatar for metalix
0
157
Member Avatar for nelliott10

I currently have the following code on my view information page which allows the user to go to a different page to update and delete the information, which can be seen below: - Update: - [CODE]<a href=\"update_line.php?barcode=".$user["barcode"]."\">Edit Line</a>[/CODE] Delete: - [CODE]<a href=\"delete_line.php?barcode=".$user["barcode"]."\">Delete Line</a>[/CODE] I also attached the other related pages …

Member Avatar for cwarn23
0
90
Member Avatar for seularts

Can anyone please help me exclude the .php files from this code? [CODE] <?php $dir = 'x'; $filecount = 0; $d = dir($dir); while ($f = $d->read()) { if(($f!= ".") && ($f!= "..")) { if(!is_dir($f)) $filecount++; } } echo 'there are ',$filecount,' files in this folder'; ?> [/CODE] I have …

Member Avatar for n_e
0
273
Member Avatar for Venom Rush

Hi all I'm creating XML with php's native DOMDocument functionality. When I try save the XML it doesn't appear on the server and I can't figure out why. [CODE=php]<?php // Initiate the XML $doc = new DOMDocument('1.0', 'UTF-8'); $doc->formatOutput = true; // Code that creates XML elements and child elements …

Member Avatar for Venom Rush
0
1K
Member Avatar for Arianna

I'm writing a simple forum system to go along with one of my projects - nothing fancy, just categories, forums, threads, and posts. Some threads, however, are marked as 'stick', which means that they're stickies. No matter how many threads there are or where they're posted on, they always must …

Member Avatar for Arianna
0
111
Member Avatar for D4n1sD

So i want to put letter limitations into text boxs, not like it will pop up an error but not be able to write letters and only numbers, as the column type in db is demical.

Member Avatar for metalix
0
160
Member Avatar for manish.mca

hello everyone, i want to generate report by php for login at specific time. and i m usin database with my sql. so plz give me favour for code to make it successful. manish

Member Avatar for n_e
0
46
Member Avatar for Carrots

Hi, I was wondering if anyone can see why the substr_replace() function isn't replacing the 'XXXXX' with the random integer I am creating in the script below: [code=php] <?php $password = rand(12345,98765); $stringtoparse = 'Your new password is XXXXX'; substr_replace($stringtoparse,$password,18); echo $stringtoparse; ?> [/code] When I run this, I still …

Member Avatar for cwarn23
0
102
Member Avatar for Th3nutz

hello guys, i'm stuck with some code and i'm getting frustrated that i cannot get it work. Please help :)) I have a database with some details about registered users with a column named Activated (which is 0 or 1). I want to make a page were restricted users can …

Member Avatar for metalix
0
118
Member Avatar for metalix

I spent a long time figuring this out on the internet so I will post this now to hopefully help others with the same problem. this is to display the currently logged in user using mysql. this is so they log in with a username, and it displays actual name. …

Member Avatar for cwarn23
0
109
Member Avatar for ayesha789

HI Dears all I have 2 tables in DB. [LIST=1] [*]Lease_north [*]Lims_payment [/LIST] My first query is [ICODE]Select * from lease_north WHERE LaStartDate like '%-04-%'[/ICODE] its shows 100 result means 100 payments are due and must be paid in April. My second query is[ICODE]Select * from lims_payment WHERE pdate like …

Member Avatar for ayesha789
0
451
Member Avatar for niths

[QUOTE]hi i am new to php. i am getting the following error ----Warning: fopen(C:/Program Files/Apache Group/Apache2/htdocs/Project/) [function.fopen]: failed to open stream: No such file or directory in C:\Program Files\Apache Group\Apache2\htdocs\Project\download.php on line 4---- ----Warning: fclose(): supplied argument is not a valid stream resource in C:\Program Files\Apache Group\Apache2\htdocs\Project\download.php on line 27------[/QUOTE] …

Member Avatar for n_e
0
281
Member Avatar for dylank

Hey DaniWeb community; I am trying to create a web page that pulls its settings from a file called settings.xml, and apply them to the web page. The title is the tag I want to change now, but my code is not working. Here is the code: [CODE=PHP] <?php //Open …

Member Avatar for dylank
0
230
Member Avatar for bigjoke

how can i REPLACE back slash in my string (file path) with forward slash. please help. str_replace doesnt seem to be working!

Member Avatar for sallecpt
0
175
Member Avatar for D4n1sD

How I can put limitation when someones submits a form so that the e-mail adress format looks like this letters@letters.2to3letters? Does anyone know?

Member Avatar for edwinhermann
0
99
Member Avatar for zeke188

[code] <?php $host="localhost"; // Host name $username=""; // Mysql username $password=""; // Mysql password $db_name=""; // Database name $tbl_name="comment"; // Table name // connect to the mysql server $link = mysql_connect($host, $username, $password) or die ("Could not connect to mysql because ".mysql_error()); // select the database $db_found = mysql_select_db($db_name) or …

Member Avatar for colweb
0
105
Member Avatar for SureshM

Hi Guys, When I am using XML version in the XHTML, then I am getting parser error [Parse error: parse error, unexpected T_STRING on line 1]. <?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-US" lang="en-US"> <head> <title>Testing Page</title> </head> <body> <p>Hi</p> </body> </html> When …

Member Avatar for twohawks
0
289
Member Avatar for SMHouston

Ok, I'm creating working on a black jack game. A very simplified version that doesn't have a dealer. Just the user and they either hit black jack or bust basically. I have the code written for a deck of cards, then shuffle it and place it into a text file. …

Member Avatar for SMHouston
0
277
Member Avatar for zeke188

Hi I have a table with info that I want to read and display. I can read it and display but I cant seem to format it can anyone tell me whats wrong. [code] <html> <head> <title>comment</title> </head> <body> <form action="postcomment.php" method="post"> name: <input type="text" name="name" ><br> comment: <textarea name= …

Member Avatar for zeke188
0
140
Member Avatar for dragos13

<?php $link=mysql_connect("localhost", "root","parola") or die("Could not connect: " . mysql_error()); mysql_select_db('energiesolara',$link) or die ('Can't use energiesolaradb: ' . mysql_error()); $x=mysql_query("SELECT umiditate FROM parametrii"); while($info=mysql_fetch_array($x)) { $comma_separated=implode(",",$info); } print "$comma_separated"; ?> I want that $comma_separated to store all the elements.But when I print that there is only one element which is …

Member Avatar for johny_d
0
93
Member Avatar for niths

[QUOTE]hi , i am new to php. i had a problem. whenever i upload a file it should get inserted in the database. it is working fine. now i should display that in a table in the browser but whenever i upload a file all other files names are not …

Member Avatar for colweb
0
61
Member Avatar for cliffordpg

my website layout breaks up when users zoom to +125% and to -65 in IE and ++2 and --2 in Firefox. Is there any way of fixing this? Website was developed in PHP and uses CSS. I know I'm not the first person to face this but I can't find …

Member Avatar for cliffordpg
0
90
Member Avatar for x86phre3x

Hi, I am in the middle of developing a web application (customer DB) and currently attempting to create a module to update the number of member registered under 1 agent. I have 2 table, 1 is 'users' and another 1 is 'dealers'. The 'users' table contains some normal user credential …

Member Avatar for johny_d
0
131
Member Avatar for peck3277

Hey guys, I'm hoping ye can help guide me here as I've reached a point in PHP where I think I can say I'm no-longer a beginner and would like to advance my knowledge. I believe my next step is understanding and using classes in PHP but for the life …

Member Avatar for xaeon
0
142
Member Avatar for Pooja J.

Hey Guys n Gals, I want to make login page in which I m taking email ID n password. If user enters email ID & password. Welcome.php should be open. else fail.php opens.Plz, read my attachments, But I received following warnings. Warning: mysql_fetch_array(): supplied argument is not a valid MySQL …

Member Avatar for Pooja J.
0
115
Member Avatar for logonchristy

how to get popup window if new row inserted into mysql database for a particular table... That to be display inserted values in popup window... Advance thanx...

Member Avatar for moncy
0
237

The End.