harshap
Forum Replies Created
-
Forum: Hacks
In reply to: wp_handle_uploadThanks for reply
clarion technologies…Will you please tell me how to upload a simple file to upload
here is my code..
if(isset($_POST[‘submit’]))
{if(count($_FILES[‘upload’][‘name’]) > 0){
//Loop through each file
for($i=0; $i<count($_FILES[‘upload’][‘name’]); $i++) {
//Get the temp file path
$tmpFilePath = $_FILES[‘upload’][‘tmp_name’][$i];//Make sure we have a filepath
if($tmpFilePath != “”){//save the filename
$shortname = $_FILES[‘upload’][‘name’][$i];//save the url and the file
$filePath = “WP_SITEURL/wp-content/uploads/product/” .$_FILES[‘upload’][‘name’][$i];//Upload the file into the temp dir
if(move_uploaded_file($tmpFilePath, $filePath)) {
$files[] = $shortname;
}
}}
}Forum: Fixing WordPress
In reply to: File uploadHello Clarion Technologies thanks for reply
I changed the permission to 0755 and even to 0777 but its still not working…Thanks
PrakashForum: Fixing WordPress
In reply to: File upload<?php
if(isset($_POST[‘submit’]))
{if(count($_FILES[‘upload’][‘name’]) > 0){
//Loop through each file
for($i=0; $i<count($_FILES[‘upload’][‘name’]); $i++) {
//Get the temp file path
$tmpFilePath = $_FILES[‘upload’][‘tmp_name’][$i];//Make sure we have a filepath
if($tmpFilePath != “”){//save the filename
$shortname = $_FILES[‘upload’][‘name’][$i];//save the url and the file
// chmod(“https://107.170.36.57/wp-content/uploads/product/”,0755);
$newfile = “https://107.170.36.57/wp-content/uploads/product/”;
if($newfile==true )
{$filePath = “https://107.170.36.57/wp-content/uploads/product/” .$_FILES[‘upload’][‘name’][$i];
echo $filePath.”
“;
}
else
{
echo “upload not possible”;
}
//Upload the file into the temp dir
chmod(“https://107.170.36.57/wp-content/uploads/product/”,0755);
if( move_uploaded_file($tmpFilePath, $filePath)== true)
{
echo “true there”;
$files[] = $shortname;}
else
{
echo “not possible”;
}
}}
/* foreach($file1 as $f)
{ echo $f.”
“; }
array_push($attachments,$f);
*/
}
$var = count($files);for($i = 0;$i < $var; $i++)
{
$val = “https://107.170.36.57/wp-content/uploads/product/”.$files[$i];
//echo $val.”
“;
$attachments[] = $val;
}
}
foreach($attachments as $a)
{
$a.”
“;}
}
this is codeForum: Fixing WordPress
In reply to: gravity formHi robhob
Thanks for your reply…
it got resolved just provided path with httsp:/path/Thanks Again
Forum: Fixing WordPress
In reply to: ParmalinksThanks
I fixed itForum: Fixing WordPress
In reply to: Widget EditThanks Resolved
Forum: Fixing WordPress
In reply to: Multi Vendor sells one ProductSorry.
Forum: Fixing WordPress
In reply to: Multi Vendor sells one ProductHi
Can we use widget as Product ?Thanks
Can a widget look like Woo-Commerce Product…
Forum: Fixing WordPress
In reply to: Multi Vendor sells one ProductOne More Can we Over write a Particular Post..
Thanks
PrakashForum: Fixing WordPress
In reply to: Multi Vendor sells one Productwe are Making a Woo-commerce website !
we want to Provide an access to the Multi vendor on the single Product.
Can different vendors sell one single Product..
With Different Seller names…Thanks
PrakashHi,
Can you help at least how to write custom code
if custom code written will woo commerce work fine ?