Quote from: banzai at Oct 03, 2006, 10:57 AM
I don’t see why you couldn’t just make up a template to display the info using the placeholders, in the same way the eForm report template does it. The placeholders don’t care what kind of container they are put in.
Quote from: banzai at Sep 26, 2006, 10:28 AM
Sorry Susan for this stupid request I only need a new chunck without input form
[[webeditprofile? &tpl=`WebEditProfileForm`]]
Parse error: parse error, unexpected ’<’ in D:\xampp\htdocs\modx\manager\includes\document.parser.class.inc.php(705) : eval()’d code on line 1Also when you say:
The snippet has a default template in the webeditprofile.inc.php file; edit the form and the postback processing section of the file to suit your web user data configuration.
remove <?php from the start of the snippet code and ?> from the end if there is one.
Parse error: parse error, unexpected ’<’ in D:\xampp\htdocs\modx\manager\includes\document.parser.class.inc.php(705) : eval()’d code on line 1
It means that by default, if you don’t supply any template in the snippet call, it will use that file as a template. So you can either edit that file directly to do any modifications to the template or copy paste it’s contents as a new chunk and define it in the snippet call.
The snippet has a default template in the webeditprofile.inc.php file; edit the form and the postback processing section of the file to suit your web user data configuration.
Do you need to paste the form contents to a separate document or just call it from there?
« MODx Parse Error »
MODx encountered the following error while attempting to parse the requested resource:
« Execution of a query to the database failed - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ’’ at line 1 »
SQL: SELECT * FROM `db181447689`.modx_web_user_attributes WHERE internalKey = ;
[Copy SQL to ClipBoard]
Parser timing
MySQL: 0.0043 s (0 Requests)
PHP: 0.0403 s
Total: 0.0446 s
The error have disappear No explanation.
I’ve tried to use the snippet but I have the following error :
« MODx Parse Error »
MODx encountered the following error while attempting to parse the requested resource:
« Execution of a query to the database failed - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ’’ at line 1 »
SQL: SELECT * FROM `db181447689`.modx_web_user_attributes WHERE internalKey = ;
[Copy SQL to ClipBoard]
Parser timing
MySQL: 0.0043 s (0 Requests)
PHP: 0.0403 s
Total: 0.0446 s
Any Idea ?
« MODx Parse Error »It seem to be the same error as in the former post
MODx encountered the following error while attempting to parse the requested resource:
« Execution of a query to the database failed - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ’’ at line 1 »
SQL: SELECT * FROM `db181447689`.modx_web_user_attributes WHERE internalKey = ;
[Copy SQL to ClipBoard]
Parser timing
MySQL: 0,0052 s (2 Requests)
PHP: 0,0793 s
Total: 0,0845 s
Not sure if you are still looking for this, but I modified the snippet to include other fields.
There are available placeholders for Gender, Comment and User Photo in the user profile?
$tpl = str_replace("[+zip+]",$userdata['zip'],$tpl);
$tpl = str_replace("[+comment+]",$userdata['comment'],$tpl);
$zip = $_POST['zip'];
$comment = $_POST['comment'];
"zip"=>$modx->db->escape($zip)
"comment"=>$modx->db->escape($comment)
<tr> <td>Zip:</td> <td> <input type="text" name="zip" class="inputBox" style="width:300px" maxlength="50" size="20" value="[+zip+]"></td> </tr>
<tr> <td>Zip:</td> <td> <input type="text" name="comment" class="inputBox" style="width:300px" maxlength="75" size="20" value="[+comment+]"></td> </tr>
<script language="javascript" type="text/javascript"> var id = "[+country+]"; var f = document.webprofilefrm; var i = parseInt(id); if (!isNaN(i)) f.country.options[i].selected = true; </script>