• twitter image
  • facebook image
  • youtube image
  • linkedin image
Language: CMS Made Simple Czech CMS Made Simple France CMS Made Simple Spain CMS Made Simple Hungary CMS Made Simple Russia CMS Made Simple Netherlands

All times are UTC




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: Form Builder - upload path
PostPosted: Thu Jun 25, 2020 10:52 am 
Offline
New Member
New Member

Joined: Thu Jun 25, 2020 10:26 am
Posts: 3
Hi,
I have inherited a CMSMS site that has not been updated from before v1.09. I have updated to CMSMS 2.2.14 and most things are working as expected, but the form that allows users to upload an image is not working as it did in the old version and I am stumped!

The old form uploaded the image and saved the following XML [these are old entries so the paths are different to the local test env I have]
<field id="33"
type="FileUploadField"
validation_type=""
order_by="3"
required="0"
hide_label="0"
display_in_submission="1">
<field_name><![CDATA[upload]]></field_name>
<options>
<option name="max_size"><![CDATA[]]></option>
<option name="permitted_extensions"><![CDATA[]]></option>
<option name="show_details"><![CDATA[0]]></option>
<option name="allow_overwrite"><![CDATA[0]]></option>
<option name="remove_file"><![CDATA[0]]></option>
<option name="file_destination"><![CDATA[/home/sites/website/public_html/uploads/feedback]]></option>
<option name="field_alias"><![CDATA[]]></option>
<option name="css_class"><![CDATA[]]></option>
<option name="helptext"><![CDATA[]]></option>
<option name="javascript"><![CDATA[]]></option>
<option name="field_logic"><![CDATA[]]></option>
<option name="file_rename"><![CDATA[]]></option>
<option name="suppress_filename"><![CDATA[0]]></option>
<option name="is_valid"><![CDATA[1]]></option>
<value><![CDATA[/home/sites/website/public_html/uploads/feedback/uploaded image.JPG]]></value>
<value><![CDATA[/uploads/feedback/uploaded image.JPG]]></value>
<human_readable_value><![CDATA[/uploads/feedback/uploaded image.JPG]]></human_readable_value>
</field>

When I use the updated version I am getting a slightly different xml. I have updated the upload form builder field setting to use my local path:

<option name="file_destination"><![CDATA[D:\path to local site\httpdocs\uploads\feedback\]]></option>

But this path is not used in the image name like is was in the previous version so it does not show in the formbrowser template.
The image does upload to exactly the same place though:

<value><![CDATA[test.jpg]]></value>
<value><![CDATA[test.jpg (outside web root)]]></value>

<human_readable_value><![CDATA[test.jpg]]>/human_readable_value>

How do I get the path back in as part of the image name? I am not sure why I have
<value><![CDATA[test.jpg (outside web root)]]></value>?

my config has the following:

$config['root_url'] = 'http://site.localhost';
$config['root_path'] = 'D:/path to local site/httpdocs';

$config['previews_path'] = $config['root_path'] . '/tmp/cache';
$config['uploads_path'] = $config['root_path'] . '/uploads';
$config['uploads_url'] = $config['root_url'] . '/uploads';
$config['image_uploads_path'] = $config['root_path'] . '/uploads/images';
$config['image_uploads_url'] = $config['root_url'] . '/uploads/images';

these are the installed modules:
AdminSearch 1.0.5
Captcha 1.0
CGExtensions 1.65.2
CGFeedback 1.3.5
CGSimpleSmarty 2.2.1
CMSContentManager 1.1.9
CmsJobManager 0.1.3
CMSMailer 6.2.14
DesignManager 1.1.8
FileManager 1.6.11
FilePicker 1.0.4.1
FormBrowser 0.5
FormBuilder 1.0.2
Gallery 2.4.2
LISE 1.3.1
MenuManager 1.50.3
MicroTiny 2.2.4
ModuleManager 2.1.7
Navigator 1.0.9
News 2.51.10
nuSOAP 1.0.2
Printing 1.1.2
Search 1.51.8
SiteMapMadeSimple 2.0.3
TinyMCE 3.3.2

Thank you for your help.


Top
  Profile  
 
Share On:
Share on Facebook Share on Twitter Share on Google+
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC


Who is online

Users browsing this forum: googlebot, SimonF, velden


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Hosting Nation - Managed CMSMS Hosting