Invision Community 4: SEO, prepare for v5 and dormant account notifications By Matt Monday at 02:04 PM
steve00 Posted August 22, 2016 Posted August 22, 2016 I have tested some html/javascript page outside of IPB software and works 100% As soon as I add it into IP.Pages (with or without the Suite HTML Wrapper) it never works All the css and javascript files load (checked that and definitely all there) Add same code back again outside of IPB and all works as it should Anyone had this problem before and if so how to fix ?
Adlago Posted August 22, 2016 Posted August 22, 2016 If you want to send me one of your html page - I'll test it in my test site. then I will write about the result.
steve00 Posted August 23, 2016 Author Posted August 23, 2016 20 hours ago, Adlago said: If you want to send me one of your html page - I'll test it in my test site. then I will write about the result. its ok, rather not send files have since found it is something to do with a script ... appears for some reason in my html page there are a few } and { close to the else tag e.g if (typeof data.prevPageToken === "undefined") {$("#pageTokenPrev").hide();}else{$("#pageTokenPrev").show();} if I make new line before and after the } then IPB Pages accepts the javascript but still will not run the script (have tried adding before the </body> and still no luck) however if I make new line before and after the } in my html file (same as IPB Pages) then the script does not work in my html version (outside of IPB)
Adlago Posted August 23, 2016 Posted August 23, 2016 22 minutes ago, steve00 said: i if (typeof data.prevPageToken === "undefined") {$("#pageTokenPrev").hide();}else{$("#pageTokenPrev").show();} Used creates Server error. So work if (typeof data.prevPageToken === "undefined") { $("#pageTokenPrev").hide(); } else { $("#pageTokenPrev").show(); }
steve00 Posted August 23, 2016 Author Posted August 23, 2016 Just now, Adlago said: Used creates Server error. So work if (typeof data.prevPageToken === "undefined") { $("#pageTokenPrev").hide(); } else { $("#pageTokenPrev").show(); } Not work ... just IPB Pages accepts the code in the 'Content' tab ... still doesn't run though But if I use that code in my html page (outside of IPB) then it doesn't work at all .. have to go back to the old code e.g. }else{ doesn't make sense to me
Recommended Posts
Archived
This topic is now archived and is closed to further replies.