CliffG Posted January 28, 2013 Share Posted January 28, 2013 Hi all, I've been lurking for months, soaking up the wisdom of the PW superheroes. A huge thank you to Ryan et al for your brilliant work. I'm about to launch my second PW site. Just one problem: Email Obfuscator is not reversing the characters upon output in 2.2.9. I don't think it's conflicting with any text formatters, as it works fine in a similar PW site running an earlier version. Any ideas? Thanks! Cliff 1 Link to comment Share on other sites More sharing options...
Wanze Posted January 28, 2013 Share Posted January 28, 2013 Hi CliffG and welcome! Do you see any errors in your javascript console? Any other "special" modules installed? Link to comment Share on other sites More sharing options...
Soma Posted January 28, 2013 Share Posted January 28, 2013 It's working fine here in all PW versions. It's not much there's that could conflict with anything in PW. Does the javascript get inserted correctly? Just to clarify, if you look in console you won't see the reversed email at all, you have to look at source code to see the reversed. Link to comment Share on other sites More sharing options...
CliffG Posted January 28, 2013 Author Share Posted January 28, 2013 Wanze and Soma, The console doesn't throw any js errors, no. The other non-core modules installed are Image Tags (problem persists when disabled) and Textile. I'm also using Ryan's great FormBuilder but not on the template where the email addresses live. >Does the javascript get inserted correctly? Just to clarify, if you look in console you won't see the reversed email at all, you have to look at source code to see the reversed. Here's the generated code when I view source: Link to comment Share on other sites More sharing options...
CliffG Posted January 28, 2013 Author Share Posted January 28, 2013 . . . Sorry . . . to continue: The generated code: <p>Email: <a href="GOSPAM:ac.kcintsec@nylorac"><span style="unicode-bidi:bidi-override; direction: rtl;" class="email-obfuscator-unreverse">ac.kcintsec@nylorac</span></a></p> I'm seeing an Error console but not a JavaScript console, which I seem to remember from the past (I'm not a scripter and don't use it) so I may be leaving some vital info out here . . . Thanks again for your help. Cliff Link to comment Share on other sites More sharing options...
Soma Posted January 28, 2013 Share Posted January 28, 2013 And what do you see on the page? Link to comment Share on other sites More sharing options...
CliffG Posted January 28, 2013 Author Share Posted January 28, 2013 And what do you see on the page? I see a correctly-formed, right-reading email address. When I hover over it, I see the reversed address. "gospam" is not replaced by mailto: and the right-reading address in the generated code. Here's the html: Email: <a href="mailto:name@myisp.com">mailto:name@myisp.com</a> There is almost certainly a simple, dumb answer here, something I'm not seeing. . . . Link to comment Share on other sites More sharing options...
Soma Posted January 28, 2013 Share Posted January 28, 2013 Then it's working everything correctly. But one thing is strange and don't know if it's the mailto: in your link text. I would remove it. I'm looking at the gen code here in PW 2.3 latest dev. <a href="GOSPAM:hc.hcilru@ppilihp"><span style="unicode-bidi:bidi-override; direction: rtl;" class="email-obfuscator-unreverse">hc.hcilru@ppilihp</span></a> And on the page it's the correct decoded text via javascript. If I click it it opens email address in mail client correctly. Link to comment Share on other sites More sharing options...
Soma Posted January 28, 2013 Share Posted January 28, 2013 Looks like the javascript file isn't included or isn't working. It requires jQuery core. Can you make sure the EmailObfuscator.js is included in either before </head> or </body>. There a module setting that allows you to enter those tags yourself. If yes, make sure it is included after jQuery core. Link to comment Share on other sites More sharing options...
CliffG Posted January 28, 2013 Author Share Posted January 28, 2013 Looks like the javascript file isn't included or isn't working. It requires jQuery core. Can you make sure the EmailObfuscator.js is included in either before </head> or </body>. There a module setting that allows you to enter those tags yourself. If yes, make sure it is included after jQuery core. Yes, it's loading right before </head>. jquery-1.4.2.min.js loads before it. Main.js and kickstart.js are also loading. The site is still in development and I haven't cleaned out unneeded code. Here's the page in question: <http://parisfashion.org/PW/testimonials/> Only the very last item has a real email link. Thanks! -- It's pretty late in Switzerland, I think. Link to comment Share on other sites More sharing options...
Soma Posted January 28, 2013 Share Posted January 28, 2013 NO it's stillll early You don't know how to look at js console? Link to comment Share on other sites More sharing options...
CliffG Posted January 28, 2013 Author Share Posted January 28, 2013 You don't know how to look at js console? Um, as I don't have any competence in js I don't as a rule look there. This seems to be the last remaining error in the kickstart.js file: ReferenceError: prettyPrint is not defined $('pre').addClass('prettyprint');prettyPrint(); Don't know where to take it from there. I'm much more comfortable with HTML & CSS and learned just enough PHP -- echo and foreach loops -- to build a very simple brochure site in PW. I referenced it to give hope to designers like me who only enter the development pool at the shallow end. I plan to learn more. . . . Link to comment Share on other sites More sharing options...
Soma Posted January 28, 2013 Share Posted January 28, 2013 No problem. Just thought it would be helpful to know when dealing with JS and building websites. prettyPrint is not defined. prettyPrint() is a function that it says is not defined. Looking at the kickstarter https://github.com/joshuagatcke/HTML-KickStart/tree/master/js I don't see the prettify.js included in your website. Link to comment Share on other sites More sharing options...
CliffG Posted January 28, 2013 Author Share Posted January 28, 2013 prettyPrint is not defined. prettyPrint() is a function that it says is not defined. Looking at the kickstarter https://github.com/joshuagatcke/HTML-KickStart/tree/master/js I don't see the prettify.js included in your website. Ah. That's because I was only using some of the functionality of the Kickstart kit (thank you, Joshua!) and didn't realize I needed prettify.js, so I didn't upload it. Problem solved. This is an embarrassing way to introduce myself to the PW community. Thank you for sticking with me, Soma, and Wanze. Cliff Link to comment Share on other sites More sharing options...
Soma Posted January 28, 2013 Share Posted January 28, 2013 Glad we figured it out and learned something. Now have a jump into the cool water it's nice in here. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now