4 of 11
4
Standalone Edit Forms
Posted: 06 May 2005 08:01 AM   [ Ignore ]   [ # 55 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  211
Joined  07-30-2002

Awesome! Any idea when it will be ready for the public?

 Signature 

31Three - Creative Services for the Design-Challenged Developer

Profile
 
 
Posted: 06 May 2005 08:17 AM   [ Ignore ]   [ # 56 ]  
Lab Assistant
RankRank
Total Posts:  300
Joined  01-30-2003

Jesse BC,

Ok it’s ready.

www.solspace.com/software

Profile
 
 
Posted: 06 May 2005 08:21 AM   [ Ignore ]   [ # 57 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  211
Joined  07-30-2002

Whoa… that was fast.

 Signature 

31Three - Creative Services for the Design-Challenged Developer

Profile
 
 
Posted: 06 May 2005 08:37 AM   [ Ignore ]   [ # 58 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1401
Joined  01-15-2005

Man!
Mitchell you’re a genius.

Thanks for your plug ins and modules.

 Signature 

EE Duration Tags | {view_count_total}

Profile
 
 
Posted: 06 May 2005 08:38 AM   [ Ignore ]   [ # 59 ]  
Lab Assistant
RankRank
Total Posts:  300
Joined  01-30-2003

Thanks EE lover. I hope you’ll let me know if you have any feature ideas or anything.

mk

Profile
 
 
Posted: 06 May 2005 09:00 AM   [ Ignore ]   [ # 60 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  133
Joined  01-25-2004

The field parser is a great idea, but I think I may have found a problem…

If you have the edit textarea set to xhtml, then with each edit the spaces between paragraphs grows. After a couple of rounds, you get something like

<p>Li Europan lingues es membres del sam familie. Lor separat existentie es un myth. Por scientie, musica, sport etc., li tot Europa usa li sam vocabularium. Li lingues differe solmen in li grammatica, li pronunciation e li plu commun vocabules.

</p>
<p>

<br />
Omnicos directe al desirabilit de un nov lingua franca: on refusa continuar payar custosi traductores. It solmen va esser necessi far uniform grammatica, pronunciation e plu sommun paroles.
</p>

And it just gets worse from there. I think it has to do with the way EE adds <p> tags after a line break, rather than immediately following the last word of a paragraph, e.g.

...sommun paroles.
</p>

instead of

...sommun paroles.</p>

But you should try it out and see for yourself, seems like it should be something fixable. Anyway, a cool feature, once it’s working.

Without the field parser, I just turn xhtml off in the stand alone edit (while keeping it on in the new entry form), think of it as a little lesson in basic html for the user wink

Profile
 
 
Posted: 07 May 2005 07:56 AM   [ Ignore ]   [ # 61 ]  
Lab Assistant
RankRank
Total Posts:  239
Joined  12-06-2002

Also having trouble with repeated editing adding extra <p> and <br /> tags. I have tried a million combinations (field formatting versus edit-field format declaration) but nothing. So…

...I’ve been trying some XHTML:Filter combinations from the Filter XHTML plugin, and it nearly works, but doesn’t.

On my edit form, a particular field needs to allow text to be broken into paragraphs by the user, using line breaks. Formatting in Custom Edit Field is XHTML, and this is also declared in the edit form. On the edit form field I include the plugin ref, disallowing use of <p> or <br /> tags:

<p>Full text<br />
<
textarea style='width:99%' name="{exp:form_helper:field_grabber field_name='body'}"
cols='90' rows='7' onclick='setFieldName(this.name)' />
[b]{exp:filter_html rules="-br -p"}[/b]{body}[b]{/exp:filter_html}[/b]</textarea></p>
<
input type="hidden" name="{exp:form_helper:field_grabber field_name='body' which='format'}"
value="br" />

This stops <p> or <br /> tags appearing on the edit form fields. Great. I then also use the plugin code on the article page, this time disallowing just <br /> tags:

[b]{exp:filter_html rules="-br"}[/b]{body}[b]{/exp:filter_html}[/b]

The aim there is to remove any break tags in the published article. I also tried it with <p> tags removed. I notice that when editing, lots of space appears between paragraphs, whether tags show or not. Anyway, the above DOESN’T work, but I’m flagging up the idea to see if Solspace or anyone can use that to make it work. There is a working combination in there somewhere, surely…

This thing is so close…

Profile
 
 
Posted: 24 May 2005 07:54 AM   [ Ignore ]   [ # 62 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  313
Joined  05-26-2004

Has anyone got a solution to the creeping <br /> <p></p> and empty space problem when using the (otherwise life-saving) Form Helper plug-in by Solspace? Solspace’s documentation mentions the use of another custom field to control this, but does not elaborate, which tantalising hint just left me in “duh” mode

 Signature 

...for there is no way to reduce a hunter to economic dependence and make him hunt for you - Albert Jay Nock ~ “Our Enemy the State”

Profile
 
 
Posted: 24 May 2005 08:59 AM   [ Ignore ]   [ # 63 ]  
Lab Assistant
RankRank
Total Posts:  300
Joined  01-30-2003

Hey JohnD,

The other custom field I think you’re referring to is the custom field that designates the formatting to be used for your custom field. When you create a custom field in EE, automatically an additional field is created in the database that tracks whether you are using XHTML, BR, or none as formatting options.
Noe of that fixes the problem that we are trying to solve. And sadly, I have not had the opportunity to troubleshoot and develop a solution to the bug described above. I’ll knock it out as soon as possible though. Thanks for using the plugin.

mk

Profile
 
 
Posted: 24 May 2005 09:44 AM   [ Ignore ]   [ # 64 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  313
Joined  05-26-2004

Yo Solspace

thanks for the update - wish I could help.

John

 Signature 

...for there is no way to reduce a hunter to economic dependence and make him hunt for you - Albert Jay Nock ~ “Our Enemy the State”

Profile
 
 
Posted: 24 May 2005 09:59 AM   [ Ignore ]   [ # 65 ]  
Moderator
Avatar
RankRankRankRankRankRankRank
Total Posts:  12416
Joined  04-29-2002

JohnD, what I do on some client sites is change the default value from xhtml to either none or br as needed on the exp_weblog_data table.

So that a new entry is set correctly without me having to add the hidden form values to switch formatting types.

Cheating, but it works.

 Signature 

Quick Reference - EE Trial Options - EE Wiki - Docs for updating a build

Profile
MSG
 
 
Posted: 24 May 2005 12:30 PM   [ Ignore ]   [ # 66 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  313
Joined  05-26-2004

Thanks Sue for that idea - a good alternative for when needs must (or is it when the devil drives?)

 Signature 

...for there is no way to reduce a hunter to economic dependence and make him hunt for you - Albert Jay Nock ~ “Our Enemy the State”

Profile
 
 
Posted: 25 May 2005 09:08 AM   [ Ignore ]   [ # 67 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  313
Joined  05-26-2004

Another Form Helper Issue

When I include an e-mail link in an entry, and then put it through the Form Helper update method, the following replaces the e-mail link:

<script type=“text/javascript”>
//<![CDATA[
var l=new Array();
l[0]=’>’;l[1]=‘a’;l[2]=’/’;l[3]=’<’;l[4]=’ 107’;l[5]=’ 117’;l[6]=’ 46’;l[7]=’ 111’;l[8]=’ 99’;l[9]=’ 46’;l[10]=’ 110’;l[11]=’ 111’;l[12]=’ 105’;l[13]=’ 116’;l[14]=’ 97’;l[15]=’ 114’;l[16]=’ 111’;l[17]=’ 116’;l[18]=’ 115’;l[19]=’ 101’;l[20]=’ 114’;l[21]=’ 103’;l[22]=’ 110’;l[23]=’ 105’;l[24]=’ 102’;l[25]=’ 111’;l[26]=’ 111’;l[27]=’ 114’;l[28]=’ 64’;l[29]=’ 110’;l[30]=’ 97’;l[31]=’ 101’;l[32]=’ 115’;l[33]=’>’;l[34]=’”’;l[35]=’ 107’;l[36]=’ 117’;l[37]=’ 46’;l[38]=’ 111’;l[39]=’ 99’;l[40]=’ 46’;l[41]=’ 110’;l[42]=’ 111’;l[43]=’ 105’;l[44]=’ 116’;l[45]=’ 97’;l[46]=’ 114’;l[47]=’ 111’;l[48]=’ 116’;l[49]=’ 115’;l[50]=’ 101’;l[51]=’ 114’;l[52]=’ 103’;l[53]=’ 110’;l[54]=’ 105’;l[55]=’ 102’;l[56]=’ 111’;l[57]=’ 111’;l[58]=’ 114’;l[59]=’ 64’;l[60]=’ 110’;l[61]=’ 97’;l[62]=’ 101’;l[63]=’ 115’;l[64]=’:’;l[65]=‘o’;l[66]=‘t’;l[67]=‘l’;l[68]=‘i’;l[69]=‘a’;l[70]=‘m’;l[71]=’”’;l[72]=’=’;l[73]=‘f’;l[74]=‘e’;l[75]=‘r’;l[76]=‘h’;l[77]=‘a ‘;l[78]=’<’;
for (var i = l.length-1; i >= 0; i=i-1){
if (l.substring(0, 1) == ’ ‘) document.write(”&#”+unescape(l.substring(1))+”;”);
else document.write(unescape(l));
}
//]]>
</script>

Other than de-activating the link, any ideas?

 Signature 

...for there is no way to reduce a hunter to economic dependence and make him hunt for you - Albert Jay Nock ~ “Our Enemy the State”

Profile
 
 
Posted: 25 May 2005 09:27 AM   [ Ignore ]   [ # 68 ]  
Research Scientist
Avatar
RankRankRankRankRankRank
Total Posts:  9868
Joined  06-19-2002

You have EE set to automatically turn email addresses into links.  Part of that process is encoding the addresses so they’re much harder for spam harvesters to get them.  You could turn off the “auto-linking” feature for emails under Admin > Weblog Management, but then the email addresses will just be plain text.

 Signature 

Chris Curtis
chriscurtis.org

Profile
 
 
Posted: 25 May 2005 09:37 AM   [ Ignore ]   [ # 69 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  313
Joined  05-26-2004

Yes, thanks Chris - turning off the automatic e-mail to link conversion via Admin > Weblog Management is certainly an option, but for now I am simply commenting out the hrefs which call the Solpsace Form Helper - seems safer since the creeping spaces <p> and <br/> problems are still a nuisance.

 Signature 

...for there is no way to reduce a hunter to economic dependence and make him hunt for you - Albert Jay Nock ~ “Our Enemy the State”

Profile
 
 
Posted: 25 May 2005 09:49 AM   [ Ignore ]   [ # 70 ]  
Research Scientist
Avatar
RankRankRankRankRankRank
Total Posts:  9868
Joined  06-19-2002

I think the ultimate solution for the “Form Helper” (and, mind you, I say this without having actually tried to use it) is to pull the entry field data straight from the database so that it hasn’t already been processed by EE.  In that way you’d have the raw content just as if you were editing in the CP.

 Signature 

Chris Curtis
chriscurtis.org

Profile
 
 
Posted: 25 May 2005 09:42 PM   [ Ignore ]   [ # 71 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  313
Joined  05-26-2004

Chris - I wondered about that, but my mysql/php skills are still at the no-confidence stage. I am going to take a look at the database(s) and structure(s) involved to educate myself, and maybe I will have an idea or two. Meanwhile I am still trying to get my head around how to use URL segments to thin out my forest of templates.

 Signature 

...for there is no way to reduce a hunter to economic dependence and make him hunt for you - Albert Jay Nock ~ “Our Enemy the State”

Profile
 
 
Posted: 27 May 2005 01:56 AM   [ Ignore ]   [ # 72 ]  
Moderator
Avatar
RankRankRankRankRankRankRank
Total Posts:  12416
Joined  04-29-2002

JohnD, I did find a workaround.

I used the pi.replacestring.php plugin to replace

’<br />’ => ‘’

Here’s a screen shot with one textarea fixed with the replace string and one without.

http://www.clientstaging.us/staging/brfix.jpg

Ignore the different heights of the text areas. Slightly different code.

This isn’t the real fix. What Chris described is what should be done.

But for the moment, it works.

 Signature 

Quick Reference - EE Trial Options - EE Wiki - Docs for updating a build

Profile
MSG
 
 
   
4 of 11
4
 
‹‹ empty new blog      MoBlog Auto Check? ››
Post Marker Legend
New Topic New posts Hot Topic Hot Topic with new posts New Poll New Poll Moved Topic Moved Topic Sticky Topic Sticky topic
Old Topic No new posts Hot Old Topic Hot Topic with no new posts Old Poll Old Poll Closed Topic Closed Topic Announcement Announcements
Theme
Change Theme
Visitor Statistics
The most visitors ever was 1149, on July 16, 2007 09:33 AM
Total Registered Members: 65011 Total Logged-in Users: 52
Total Topics: 82079 Total Anonymous Users: 46
Total Replies: 441119 Total Guests: 312
Total Posts: 523198    
Members ( View Memberlist )