okay hopefully someone can help me with this issue...i have a picture upload functionality for my website, but ever since i tried uploading a file, it brings up this error message. Does anybody know what is wrong ? and if so i would appreciate your help. Here is file/code that corresponds with the photo functionality and error. it is called changephoto.phtml <?php $this->placeholder("pagecontent")->captureStart(); ?> <div id="navpanel"> <a href="<?php echo $this->appbasepath.'/' ?>"><?php if($this->enablecustomtext){if(isset($this->statictext)){$node = $this->statictext->xpath("/statictexts/normaltext/entry[@ID='24']/replaced"); echo $node[0];}else{echo 'Home';}}else{echo 'Home';} ?></a> > <a href="<?php echo $this->url(array(), 'myprofile', true) ?>"><?php if($this->enablecustomtext){if(isset($this->statictext)){$node = $this->statictext->xpath("/statictexts/normaltext/entry[@ID='10']/replaced"); echo $node[0];}else{echo 'My Profile';}}else{echo 'My Profile';} ?></a> > <span class="pagetitle"><?php if($this->enablecustomtext){if(isset($this->statictext)){$node = $this->statictext->xpath("/statictexts/normaltext/entry[@ID='63']/replaced"); echo $node[0];}else{echo 'Change Photo';}}else{echo 'Change Photo';} ?></span> </div> <?php if(isset($this->formdata->adplaceholder6) && $this->formdata->adplaceholder6->isactive == true){ ?> <div id="adplaceholder6"> <?php echo $this->formdata->adplaceholder6->content ?> </div> <?php } ?> <div style="padding: 10px;"> <!-- start# right panel --> <div style="float: right; width: 220px; text-align: left;"> <?php if(isset($this->formdata->adplaceholder5) && $this->formdata->adplaceholder5->isactive == true){ ?> <div id="adplaceholder5"> <?php echo $this->formdata->adplaceholder5->content ?> </div> <?php } ?> </div> <!-- end# right panel --> <form id="frm" method="post" enctype="multipart/form-data"> <input type="hidden" name="posted" value="1" /> <input type="hidden" name="frmAction" value="<?php echo isset($this->formdata->frmAction) ? $this->formdata->frmAction : '' ?>" /> <div id="profilepanel"> <?php echo isset($this->errormsg) ? '<div class="error">### '.$this->errormsg.' ###</div>' : '' ?> <span style="font-size: 8pt; font-style: italic"> <?php if($this->enablecustomtext){if(isset($this->statictext)){$node = $this->statictext->xpath("/statictexts/normaltext/entry[@ID='64']/replaced"); echo $node[0];}else{echo 'Changing photo is 2 step procedure. First you have to upload the photo, and then crop it.';}}else{echo 'Changing photo is 2 step procedure. First you have to upload the photo, and then crop it.';} ?> </span> <br /><br /> <fieldset> <legend> <img alt="" src="<?php echo $this->appbasepath ?>/images/photo.png" style="vertical-align: middle;" /> <strong><?php if($this->enablecustomtext){if(isset($this->statictext)){$node = $this->statictext->xpath("/statictexts/normaltext/entry[@ID='65']/replaced"); echo $node[0];}else{echo 'Upload Photo';}}else{echo 'Upload Photo';} ?></strong> </legend> <div style="padding: 5px;"> <span class="fieldheader"><?php if($this->enablecustomtext){if(isset($this->statictext)){$node = $this->statictext->xpath("/statictexts/normaltext/entry[@ID='66']/replaced"); echo $node[0];}else{echo 'Specify Photo';}}else{echo 'Specify Photo';} ?></span> <input type="file" name="photo" class="textbox" style="width: 350px;" /> </div> </fieldset> </div> <div style="text-align: center; width: 65%; padding-left: 10px; padding-right: 10px; padding-top: 5px;"> <button type="submit" class="frmbttn"><img alt="" src="<?php echo $this->appbasepath ?>/images/upload.png" /> <?php if($this->enablecustomtext){if(isset($this->statictext)){$node = $this->statictext->xpath("/statictexts/normaltext/entry[@ID='67']/replaced"); echo $node[0];}else{echo 'Upload';}}else{echo 'Upload';} ?></button> <button type="reset" class="frmbttn"><img alt="" src="<?php echo $this->appbasepath ?>/images/reset.png" /> <?php if($this->enablecustomtext){if(isset($this->statictext)){$node = $this->statictext->xpath("/statictexts/normaltext/entry[@ID='55']/replaced"); echo $node[0];}else{echo 'Reset Form';}}else{echo 'Reset Form';} ?></button> </div> </form> <div style="clear: both;"></div> </div> <?php $this->placeholder("pagecontent")->captureEnd(); ?> PHP:
the code you posted has no relevance in the upload functionality, it will just display the upload form. maybe post a screenshot of the page displaying the error?
this line of code displays that part.. <?php echo isset($this->errormsg) ? '<div class="error">### '.$this->errormsg.' ###</div>' : '' ?> PHP: but we still need the uploading script in which $this->errormsg is set.. what PHP framework are you using or CMS?