28, May 2012

I need to add filename and path to mysql table - webmaster forum

 
Webdigity webmaster forums
[ Home | Help | Search | Forum's Shop | Archive | Login | Register | Webmaster Directory ]
Webdigity Webmaster Forums  >  Web Development  >  PhP  >  PHP classes @finalwebsites.com  >  Easy PHP Upload (Moderator: Olaf)
Topic: I need to add filename and path to mysql table
« previous next »
Pages: [1] Print
Instabuck - The easy way to sell digital products online

Author Topic: I need to add filename and path to mysql table  (Read 2221 times)
Bill Cosby is my Father
*
Posts: 4
28 credits
Members referred : 0


« on: Mar 03, 2007, 01:17:40 pm »

I am new to php. I tried the easy upload got the files uploaded to default folder. Actually my placement (Jobfinder) site where candidates can register their details in a mysql table (table also has a resume column) and upload their resume *.doc files. I want the name and full path of the resume file be stored in resume column of mysql table.

Can you please help me with an example file where visitor types his username in a text box and then uploads the file. After pressing the submit button files is uploaded and username and path of file is stored in a mysql table. (Say table has three columns, 1) ID, 2) Username 3) Full Path with file name.

This will hwlp me know which resume belongs to which candidate.

Regards,
Imran
I am a metal monkey!
Administrator
Community Supporter ?
Jedai Sword Master
*****
Gender: Male
Posts: 5799
46391 credits
Members referred : 3



« Reply #1 on: Mar 03, 2007, 01:23:35 pm »

No offense Imran, but are you looking to learn how to do that, or you want someone to do it for you?

I am asking because in the second case you should have to post here Wink

Trial and Error my two best teachers Cool
Join us @ facebook or twitter

Last blog : Butterfly Marketing 2.0
Moderator
Community Supporter ?
Jedai Sword Master
*****
Gender: Male
Posts: 6691
34714 credits
Members referred : 374


It's time to use PHP5!


« Reply #2 on: Mar 03, 2007, 01:51:28 pm »

the "upload_db_example.php" has exactly this function.

If you have problems with changing this code that it works within your application than you should follow Nick's advice...

Bill Cosby is my Father
*
Posts: 4
28 credits
Members referred : 0


« Reply #3 on: Mar 03, 2007, 04:55:56 pm »

I am new to PHP. I am learning while developing sites for my clients.
I am located in India and engaged in providing computer education.
If required I can post on other optional forum too.

I am using the following code to insert

$insert = "INSERT INTO employee (employeeusername, employeepassword, resume, employeename, address, city, pincode, state, country, email, website, telephone, mobile, fax, professionaltitle, dateofbirth, status)
VALUES ('".$_POST['employeeusername']."', '".$_POST['employeepass']."', '".basename($name)."', '".$_POST['employeename']."', '".$_POST['address']."', '".$_POST['city']."', '".$_POST['pincode']."', '".$_POST['state']."', '".$_POST['country']."', '".$_POST['email']."', '".$_POST['website']."', '".$_POST['telephone']."', '".$_POST['mobile']."', '".$_POST['fax']."', '".$_POST['ptitle']."', '".$_POST['birthday']."', '".$_POST['status']."')";
$add_member = mysql_query($insert);

This code I am using in upload_class.php
Moderator
Community Supporter ?
Jedai Sword Master
*****
Gender: Male
Posts: 6691
34714 credits
Members referred : 374


It's time to use PHP5!


« Reply #4 on: Mar 03, 2007, 05:19:30 pm »

check the example there is the answer...

Bill Cosby is my Father
*
Posts: 4
28 credits
Members referred : 0


« Reply #5 on: Mar 04, 2007, 07:43:58 am »

O.K. I'll start again from begining to understand the example.

Thank you.
Bill Cosby is my Father
*
Posts: 4
28 credits
Members referred : 0


« Reply #6 on: Mar 04, 2007, 08:02:18 am »

Hey I got it its $fullpath to be used there.

Thanks any way.
Moderator
Community Supporter ?
Jedai Sword Master
*****
Gender: Male
Posts: 6691
34714 credits
Members referred : 374


It's time to use PHP5!


« Reply #7 on: Mar 04, 2007, 11:31:41 am »

 Smiley

Trackback URI for this entry : http://www.webdigity.com/trackback.php?topic=6146
Tags : Filename with username be stored in mysql table Bookmark this thread : Digg Del.icio.us Dzone more....

Pages: [1] Print 
Webdigity Webmaster Forums  >  Web Development  >  PhP  >  PHP classes @finalwebsites.com  >  Easy PHP Upload (Moderator: Olaf)
Topic: I need to add filename and path to mysql table
« previous next »
Jump to:
User Area
Welcome, Guest. Please login or register.
Did you miss your activation email?
May 28, 2012, 06:44:09 pm





Login with username, password and session length

Donate to our community, and get a permanent link back to your site!

Donate to our community, and get a permanent link back to your site!






Web Design Gallery · Whois Lookup · Pagerank · Tag Browsing · Lo-fi version · Syndication · Webmaster forum history · Advertise
Developed by HumanWorks © 2005 - 2012 Webdigity webmaster community · sublime directory
Webdigity Webmaster Forums | Powered by SMF 1.0.12. © 2001-2005, Lewis Media. All Rights Reserved.