close ad
Databridge V2 with MySQLi support IS Now Available!
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

Creating queries

Thread began 2/18/2020 10:38 pm by balexander389215 | Last modified 3/16/2020 3:18 pm by balexander389215 | 110 views | 20 replies

balexander389215

Ray I have been working on the image upload section we created. I am having two different problems. First i am trying to copy this over to the venue registration page to allow image here as well. this is a different table so I created the column for the images and made the appropriate changes in the coding for this but I cannot get it to upload images.

<?php
// WA_UploadResult2 Params Start
$WA_UploadResult2_Params = array();
// WA_UploadResult2_1 Start
$WA_UploadResult2_Params["WA_UploadResult2_1"] = array(
'UploadFolder' => "images/venueimage",
'FileName' => "[FileName]",
'DefaultFileName' => "",
'ResizeType' => "0",
'ResizeWidth' => "120",
'ResizeHeight' => "120",
'ResizeFillColor' => "#FFFFFF" );
// WA_UploadResult2_1 End
// WA_UploadResult2 Params End
?>
<?php
WA_DFP_SetupUploadStatusStruct("WA_UploadResult2");
if(isset($_POST["RichRegistration_submit"]) || isset($_POST["RichRegistration_submit_x"])){
WA_DFP_UploadFiles("WA_UploadResult2", "venueimage", "2", "[NewFileName]_[Increment]", "true", $WA_UploadResult2_Params);
}
?>

$InsertQuery->bindColumn("venue_image", "s", "".$WA_DFP_UploadStatus["WA_UploadResult2"]["WA_UploadResult2_1"]["serverFileName"] ."", "WA_BLANK");

<li class="formItem">
<div class="formGroup">
<div class="lineGroup">
<div class="fullColumnGroup">
<label for="venueimage" class="sublabel" > Image:</label>
<input type="file" id="venueimage" name="venueimage" />
</div>

The second is I'm trying to duplicate the code on a page to add a second image but I can't get this to work either. I have been marginally successful in that in one of the trials I did get two images up, one for each column in the table but it brought the dame image to both even though different ones were selected.I've tried altering parameters but that usually results in a complete failure. Can you tell me which parameters need to be changed to allow for two images to be uploaded.

// WA_UploadResult2 Params Start
$WA_UploadResult2_Params = array();
// WA_UploadResult2_1 Start
$WA_UploadResult2_Params["WA_UploadResult2_1"] = array(
'UploadFolder' => "images/memberimage",
'FileName' => "[FileName]",
'DefaultFileName' => "",
'ResizeType' => "0",
'ResizeWidth' => "120",
'ResizeHeight' => "120",
'ResizeFillColor' => "#FFFFFF" );
// WA_UploadResult2_1 End
// WA_UploadResult2 Params End
?>

<?php
WA_DFP_SetupUploadStatusStruct("WA_UploadResult2");
if(isset($_POST["RichRegistrationCountryCode_submit"]) || isset($_POST["RichRegistrationCountryCode_submit_x"])){
WA_DFP_UploadFiles("WA_UploadResult2", "execimage", "2", "[NewFileName]_[Increment]", "true", $WA_UploadResult2_Params);
}
?>
<?php
// WA_UploadResult2 Params Start
$WA_UploadResult2_Params = array();
// WA_UploadResult2_1 Start
$WA_UploadResult2_Params["WA_UploadResult2_1"] = array(
'UploadFolder' => "images/memberimage",
'FileName' => "[FileName]",
'DefaultFileName' => "exec.png",
'ResizeType' => "0",
'ResizeWidth' => "120",
'ResizeHeight' => "120",
'ResizeFillColor' => "#FFFFFF" );
// WA_UploadResult2_1 End
// WA_UploadResult2 Params End
?>

<?php
WA_DFP_SetupUploadStatusStruct("WA_UploadResult2");
if(isset($_POST["RichRegistrationCountryCode_submit"]) || isset($_POST["RichRegistrationCountryCode_submit_x"])){
WA_DFP_UploadFiles("WA_UploadResult2", "execimage2", "2", "[NewFileName]_[Increment]", "true", $WA_UploadResult2_Params);
}
?>

$InsertQuery->bindColumn("member_image", "s", "".$WA_DFP_UploadStatus["WA_UploadResult2"]["WA_UploadResult2_1"]["serverFileName"] ."", "WA_BLANK");
$InsertQuery->bindColumn("member_image2", "s", "".$WA_DFP_UploadStatus["WA_UploadResult2"]["WA_UploadResult2_1"]["serverFileName"] ."", "WA_BLANK");

<li class="formItem">
<div class="formGroup">
<div class="lineGroup">
<div class="fullColumnGroup">
<label for="execimage" class="sublabel" > BIO Image:</label>
<input type="file" id="execimage" name="execimage" />
</div>
</div>
</div>
</li>
<li class="formItem">
<div class="formGroup">
<div class="lineGroup">
<div class="fullColumnGroup">
<label for="execimage2" class="sublabel" > BIO Image:</label>
<input type="file" id="execimage2" name="execimage2" />
</div>
</div>
</div>
</li>

Thanks

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...