I want to increase the limit of upload size max, but because I using shared hosting, I cannot edit php.ini. Then I try to edit my .htaccess file. I added these lines: php_value upload_max_filesize 700M php_value post_max_size 700M php_value max_execution_time 600 php_value max_input_time 600 When I test it in localhost, it running succedded. But, when I upload this .htaccess file to my shared hosting, it produce 500 Internal Server Error. I also try to put that similar code in my .php files, but not affected. Any idea how to solve this problem? Thanks a lot.

Member Avatar
Member Avatar
+0 forum 2

Hi.. I want to upload a file with help of FileUpload control, in which, i want to save the file with a specific name or say a name entered in a textbox on a same page. for ex, if textbox contains "ABC" then the files should be uploaded with abc.jpg name. how can i restrict user to select only specific types of file in a fileupload control? also, how can i save an image in 3 different sizes at time of uploading? when user selects an image, it should be saved in some specific size in a specified folder with …

Member Avatar
Member Avatar
+0 forum 10

Hi People; I've got issue in uploading image in cake php. Thing is that, I have a form, where i have input type="file". I need to upload a file in a directory and save its path in database. In "view" its like... <tr><td> <?php echo $this->Form->input('field', array( 'type' => 'file', 'label' => 'Please Upload Signature of Sales Manager' )); ?> </td></tr> and in the "Controller" its like $dir = WWW_ROOT.'documents'; $slas= '\'; $filenamez= $this->data['Invoice']['field']['name']; $dir=$dir.$slas.$filenamez; echo $dir; move_uploaded_file($this->data['Invoice']['field']['tmp_name'],$dir); I'm getting this error.... SQL Query: UPDATE `acm`.`invoices` SET `last_modified` = '2013-06-24 10:10:16', `last_mod_by` = 'Admin User', `invoice_number` = '1306190003', `invoice_date` = …

Member Avatar
Member Avatar
+0 forum 7

hi all i have got a problem with my profile photo upload script after converting to mysqli everytime i go to upload a image i get the following error: Strict Standards: Only variables should be passed by reference in /home/matureco/public_html/registration2.php on line 11 and the code for that section is as follows: //For Uploading Profie pic if(isset($_POST['sub1'])) { //$fn = date('U').$_FILES['userimage']['name']; $ext = end(explode('.',$_FILES['userimage']['name'])); ---THIS LINE--- $fn = date('U').".".$ext; $ft = $_FILES['userimage']['type']; $fs = $_FILES['userimage']['size']; $ftmp = $_FILES['userimage']['tmp_name']; move_uploaded_file($ftmp, "images/user_images/$fn"); $thumb = new Thumbnail('images/user_images/'.$fn); $thumb->resize(100,100); $thumb->save('images/user_images/smallthumb/'.$fn); $thumb1 = new Thumbnail('images/user_images/'.$fn); $thumb1->resize(405,540); $thumb1->save('images/user_images/bigthumb/'.$fn); If anyone can give me a idea what …

Member Avatar
Member Avatar
+0 forum 2

In this example opening url in webview and showing progress Dialog for page. Show file chooser option on clicking file option for web form . Open new link from webview to external ............................ Read More

Member Avatar
Member Avatar
-2 forum 2

Dear All, I am facing a weird problem, similar codings give different result. Why is this happening? I am saving both files as .php file. Please guide me. I really having headache with this form. Code 1: Working Fine (Non-bootstrap) <html> <head> TestPage <link rel="stylesheet" href="http://gsmtecharena.com/Testing/bootstrap/3.3.5/css/bootstrap.min.css"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script> <script src="http://http://gsmtecharena.com/Testing/bootstrap/3.3.5/js/bootstrap.min.js"></script> </head> <body> <div> <?php include("img-upload.php"); ?> <form method="post" action="img-upload.php" name="registerform" id="registerform"> <fieldset> <label for="username">Username:</label><input type="text" name="username" id="user_id" /><br /> <label for="password">Password:</label><input type="password" name="password" id="ap_id" /><br /> <label for="email">Email Address:</label><input type="text" name="email" id="email" /><br /> <input type="submit" name="register" id="register" value="Register" class="btn btn-info" /> </fieldset> </form> <form name="Image" enctype="multipart/form-data" method="POST"> <table cellspacing=2 …

Member Avatar
Member Avatar
+0 forum 4

Good day everyone I just want to know whether its possible to upload a file using joomla that wouldnt be downloable at all, I tried saving the file as a read only pdf file but that still made the file downloable on the web. Taking into consideration that the internet is hard to contriol I just want to explore all possble suggestion prior to me concluding that it would be impossible. Thanks in advance.

Member Avatar
Member Avatar
+0 forum 4

Hi i am making an application in vb.net and i need help. The user will send me his issues or information through attachment. but i want a restriction on filesize that he can not attach file more then 20MB i did some coding but its not working. it will show the size of file but not axectly the size in MB.. dim filesize=my.computer.filesystem.getfileinfo(textbox1.text) msgbox filesize.length now in above code it will show me the size of file in textbox1 but in bit like 1234567 i need it to show me in MB like 1MB or 10KB Thanks

Member Avatar
Member Avatar
+0 forum 5

Dear all, I have created a website where I would like my users to register and upload profile images to my server and then store it under folder in my server known as "images" and then save the dataurl of the images into MySQL database. Then, I would display their profile picture on a page known as "profile.html" into row and resize the images into 60x60 pixels images. I have no idea how to do this. I have found and read through a lot of thread ut I did not find any related information. Anyone can help me with this? …

Member Avatar
Member Avatar
+0 forum 4

protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { response.setContentType("text/html"); PrintWriter pw = response.getWriter(); InputStream inputStream = null; // input stream of the upload file // obtains the upload file part in this multipart request Part filePart = request.getPart("audio"); if (filePart != null) { // prints out some information for debugging System.out.println(filePart.getName()); System.out.println(filePart.getSize()); System.out.println(filePart.getContentType()); // obtains input stream of the upload file inputStream = filePart.getInputStream(); } String message = null; // message will be sent back to client try { // connects to the database DriverManager.registerDriver(new com.mysql.jdbc.Driver()); // Class.forName(driver).newInstance(); conn = DriverManager.getConnection(url, "root", "root"); // constructs SQL statement String …

Member Avatar
Member Avatar
+0 forum 4

Please help me.... I want to upload up to 5 photos and save in database. I want by selecting photo it will upload automatically and then the selected photo will appear in the page. It will occure with one by one photo, up to 5 photos and the photos can be seen in the page. Then if i submit it, it will save the photos (not the photo link) in a table named ads in my database named my_db.

Member Avatar
Member Avatar
+0 forum 1

hi I am new with ajax and i want to multiple image upload in a ads post site. please help me

Member Avatar
Member Avatar
+0 forum 1

I'm studying the Swift Mailer, and wondered if there is someone in here that is familiar enough with the way it works, that you could give me a little guidance. I have a form that I created that allows someone to enter their information as required, and that works just fine. Once submitted, it generates an email that is sent to the company, and a copy is sent to the person submitting it. Currently I am using mail() in a mailing function that I have that isn't related to Swift Mailer. I need to give the submitter the opportunity to …

Member Avatar
Member Avatar
+0 forum 11

Here's dish. When I submit a form, it straight up crashes my site on my network. Here are the details. 1. The form submits to itself. The form is on site.php (fictional name for reference on this post) and the action= "site.php". 2. When it crashes, it crashes for every page on my site I try to visit. Other sites work. And it's only on my network. While it's in crash mode, others on different networks can visit the site. ANd it doesn't fully crash on my mobile network. Just for site.php. 3. I have to fully reboot the modem …

Member Avatar
Member Avatar
+0 forum 1

Me again... So now I am confused... I have a form: <form action="addanimal_submit.php" method="post" enctype="multipart/form-data" style="padding-left:10px"> <p>Name: <input type="text" name="name"></p> <p>Date of Birth: <input type="text" name="dateofbirth"></p> <p>Description: <input type="text" name="description"></p> <p>Available For Adoption? <select type="text" name="available"> <option value="1" selected>Yes</option> <option value="0">No</option> </select> </p> <p>Image Of Animal:</p> <p><input type="file" name="fileToUpload"></p> <input type="submit" name="submit" value="Submit Details" /> </form> however when I submit it and echo the vars on the new form, none exist. If I get rid of the `<input type="file">` then it magically works. What is the catch with having a file upload and additional data in the same form? It …

Member Avatar
Member Avatar
+0 forum 8

i want to make an application, where user can upload their images and display it in Image control without physically saving it in a folder on disk. after done build the cone, an error show on this line. Dim base64String As String = Convert.ToBase64String(bytes, 0, bytes.Length) Error show on the attachment below. ![7.PNG](/attachments/large/4/16e09c0e45d228f7decb4a7bfeaa3352.PNG "align-center") Here my full code : Partial Class _Default Inherits System.Web.UI.Page Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click Dim fs As System.IO.Stream = FileUpload1.PostedFile.InputStream Dim br As New System.IO.BinaryReader(fs) Dim bytes As Byte = br.ReadBytes(CType(fs.Length, Integer)) Dim base64String As String = Convert.ToBase64String(bytes, …

Member Avatar
Member Avatar
+0 forum 2

Hi I am getting error this error while upload image? Error:Fatal error: Class 'Image' not found Code: $gallerycate_img = "gallerycateimg/".$_FILES["txt_photo"]["name"]; $gallerycate_image = $_FILES['txt_photo']['name']; if (($_FILES["txt_photo"]["type"] == "image/jpeg")||($_FILES["txt_photo"]["type"] == "image/jpg")||($_FILES["txt_photo"]["type"] == "image/gif")||($_FILES["txt_photo"]["type"] == "image/png")&& ($_FILES["txt_photo"]["size"] < 200000000)) { move_uploaded_file($_FILES["txt_photo"]["tmp_name"], "../gallerycateimg/" .$_FILES["txt_photo"]["name"]); copy("../".$gallerycate_img, "../gallerycateimg/thumb/".$gallerycate_image); $file_thumb="../gallerycateimg/thumb/".$gallerycate_image; $file_thumb_1="gallerycateimg/thumb/".$gallerycate_image; $img = new Image($file_thumb); $size = $img->getSize(); if($size['width']>350) $img->resize(350)->save(); elseif($size['height']>300) $img->resize(null, 250)->save();

Member Avatar
Member Avatar
+0 forum 1

My problem is why this codes dont work. i want to upload image with hide input type file but doesnt work. here are my codes.. <form action="" method="post" enctype="multipart/form-data"> <div id ="settingmaincontainerright"> <input type="file" id="settingprofileimgfile" name ="settingprofileimgfile" > <input type="submit" id="settingprofileimgfilebutton" name="settingprofileimgfile" value="Choose Foto"> <input type="submit" id="settingprofileimgbutton" name="settingprofileimg" value="Upload Foto"> </div> </form> This is css. #settingprofileimgfile{ width:100%; height:100px; display:none; } #settingprofileimgfilebutton{ width:100%; height:100px; border-top-right-radius: 30px; cursor:pointer; } #settingprofileimgbutton{ width:100%; height:100px; border-bottom-right-radius: 30px; cursor:pointer; } #settingmaincontainer{ width:90%; margin:auto; border:3px solid #FF4500; border-radius:30px; height :200px; margin-top:10px; } Here is JS.. $(function(){ $("#settingprofileimgfilebutton").click(function() { $("#settingprofileimgfile").click(); }); });

Member Avatar
Member Avatar
+0 forum 8

I have database 'website' having fields - title, url, snapshot to collect information of websites . Users will fillup the form so, There is no file input for fileupload. Form have inputs for title & url. How to generate snapshot using 'imagegrabwindow' or other php functions for given url? How to upload generated image to 'uploads' & insert data to mysql database( title, url, snapshot)?

Member Avatar
Member Avatar
+0 forum 1

Good Morning all, Hopefully someone can head me in the right direction. I know nothing about perl or cgi but have a script that I purchased and had modified by a programmer half way around the world. He uploaded it to my development domain and the script works just fine... I downloaded it to my local system for storage and then uploaded it to my Live/Production domain, and I get nothing but the error screen saying 500 Internal Server error. Through some investigation I determined that it may be a permissions error, so I set the permissions to 755 as …

Member Avatar
Member Avatar
+0 forum 4

With following code I tried to upload image and video file at the same time but, image file is uploading & video file is not uploading <form class="pure-form pure-form-aligned" action="Processor.php" method="post" enctype="multipart/form-data" > <fieldset> <div class="pure-control-group"> <label for="image">Upload image</label> <input type="file" name="image" class="pure-input-1-4" /> </div> <div class="pure-control-group"> <label for="video">Upload video</label> <input type="file" name="video" class="pure-input-1-4" /> </div> </fieldset> <div class="pure-controls"> <input type="submit" name="submit" value="Submit" class="pure-button pure-button-primary" /> </div> </form> **php** $target1 = "../image/"; $target2 = time() . rand(11, 99). basename( $_FILES['image']['name']) ; $target3 = $target1 . $target2; $target4 = "../video/"; $target5 = time() . rand(11, 99). basename( $_FILES['video']['name']) ; $target6 = …

Member Avatar
Member Avatar
+0 forum 16

i am trying to create a site, when user create his account then make automatic his directory with his name. when he wants to upload his photos, these photos go automatic in his folder or directory. im my register page i have added these lines: $addtothedb="INSERT INTO login (firstname,lastname,useremail,password,Gender,Dateofbirth) VALUES ('". $fristname . "','". $laname ."','" . $email . "','". $pass ."','". $sgender . "','". $date . "')" ; $result=mysqli_query($con,$addtothedb); $cur = "USERS/"; $gofile=$cur.$email; if($result){ if ( mkdir($gofile,0777) ) { } else { } echo " <div id='success'> Account Successfully Created. <br> Now you can Login. </div>"; } else { …

Member Avatar
Member Avatar
+0 forum 6

Hello, I have a script that allows user to upload a file to a mysql 5 database. That is working OK. The File size is accurate. However, my download script is for some reason downloading the files without any content - 0KB. The files are OK when I open them directly. I have tried code with .doc, .pdf, .txt and the same result. Here is my code for viewing the files: [CODE] <?php ini_set('display_errors', E_ALL); include "open_db.inc"; $sql = "SELECT * FROM tbl_Files "; $sql .= "ORDER BY filename ASC"; $result = mysql_query($sql, $db); $rows = mysql_num_rows($result); echo "<table>\n"; echo …

Member Avatar
Member Avatar
+0 forum 17

I get an errror when trying to upload a profile photo. The upload destination folder does not appear to be writable.

Member Avatar
Member Avatar
+0 forum 9

Hello guys have a nice day.. I have a problem need to be solved, I have upload script which save files in "/uploads" folder everything was going good until my boss decided to move upload file to storage server and need to store all files in "/etc/mnt/storage/uploads" so what should i do, and what changes i Should made to my script or my server configration to achive this.

Member Avatar
Member Avatar
+0 forum 12

I wanted to upload an excel file with one of my threads, but it is refused. Do I have to zip it first and if so, why?

Member Avatar
Member Avatar
+0 forum 5

When there should be a error it does not show. I can not seem to get the erorrs to work in the correct order How can I improve my file upload errors to work in correct order? public function upload() { $name = $_FILES['userfile']['name']; $tmp_name = $_FILES['userfile']['tmp_name']; $type = $_FILES['userfile']['type']; $size = $_FILES['userfile']['size']; $error = $_FILES['userfile']['error']; for($i = 0; $i < count($tmp_name); $i++) { $dir = FCPATH . "upload/"; if (is_dir($dir)) { if (!empty($name[$i]) && is_file($name[$i])) { // Allowed file extension types $allowed = array( 'jpg', 'jpeg', 'gif', 'png' ); if (in_array(utf8_strtolower(utf8_substr(strrchr($name[$i], '.'), 1)), $allowed)) { $this->error['warning'] = 'Incorrect File …

Member Avatar
Member Avatar
+0 forum 2

When I upload I can upload single files fine but, I cannot seem to upload if input is like **<input type="file" name="file[]">** I am not sure on my php upload function how to make it allow multiple files? Thanks in advance. public function upload() { $this->load->library('request'); $directory = FCPATH .'upload/'; $full_path = $directory . basename($this->request->files['file']['name']); $file_name = basename($this->request->files['file']['name']); $file_ext = array('jpeg', 'jpg', 'gif','png'); $file_size = 3000; if (is_dir($directory)) { if (!move_uploaded_file($this->request->files['file']['tmp_name'], $full_path)) { if (!in_array(utf8_strtolower(utf8_substr(strrchr($file_name, '.'), 1)), $file_ext)) { $this->error['warning'] = 'Warning: Incorrect file type!'; } if ($_FILES["file"]["size"] < $file_size) { $this->error['warning'] = 'Warning: Incorrect file size!'; } return !$this->error; …

Member Avatar
Member Avatar
+0 forum 3

Okay I have a html upload form here, What is does is displays a browse button so users can upload files to my site, what I want them to be able to do is completly rename the file that they are uploading once they upload it to my site, but always add the extensions .mp4, so say I upload a video named sample123.mp4 and I rename the video to funny. I want the file to be saved in my directory as funny.mp4. But be saved into my database table as funny. <?PHP require_once("./include/membersite_config.php"); if(!$fgmembersite->CheckLogin()) { $fgmembersite->RedirectToURL("login.php"); exit; } ?> <!DOCTYPE …

Member Avatar
Member Avatar
+0 forum 3

Hi good people of Danniweb, I've looked at a lot of examples on line and I cannot figure out what is going wrong. My program has to transfer a simple delimited text file from the local machine up to a specified directory on a FTP server. After I have run the routine, I can see the file in the correct directory in the FTP server BUT it is empty i.e. no text. I tried copying the same file to the same directory via windows explorer and it copied up so I don't think there is an issue with rights or …

Member Avatar
Member Avatar
+0 forum 5

The End.