The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

problem at posting_body adding a Script

View previous topic View next topic Go down

Solved problem at posting_body adding a Script

Post by Michael_vx on August 30th 2016, 3:43 pm

trying to add the Script
http://pastebin.com/7vAScdYh
into the posting _body template
but it fails the template refuse even a letter at line 990
is there a way to fix that

Michael_vx
Forumember

Male Posts : 655
Reputation : 29
Language : Arabic and some English
Location : Egypt

Back to top Go down

Solved Re: problem at posting_body adding a Script

Post by Ange Tuteur on August 30th 2016, 5:01 pm

Hi @Michael_vx,

It appears the template is too big. You can try minifying it :
http://www.willpeavy.com/minifier/

Another solution would be to optimize it by replacing unnecessary style attributes with class names. Like these :
Code:
style="font-stretch: normal; font-size: 11pt; border: 2px groove; padding: 6px; width: 100%; background: rgb(225, 225, 226);"
Those are taking up a lot of space and would be better added in the stylesheet.

Ange Tuteur
Forumaster

Male Posts : 13021
Reputation : 2684
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: problem at posting_body adding a Script

Post by Michael_vx on August 31st 2016, 8:53 am

even with minifying it still wont help
as my anylize
the max size for that template was 65.3 KB as a txt file
the Script size in txt is about 90 KB before minifying
after minifying 70 KB
ok now i have one of 2
1 - is a way to let the Script load from out side like the LG like system but i have no idea about HTML since the LG like system is a Java
2 - is try to do as you said and spare the styling into CSS
if the line 1 cant be done then topic is closed Smile
thanks so much in advance

Michael_vx
Forumember

Male Posts : 655
Reputation : 29
Language : Arabic and some English
Location : Egypt

Back to top Go down

Solved Re: problem at posting_body adding a Script

Post by Ange Tuteur on August 31st 2016, 6:01 pm

1. Unfortunately template-wise it's not entirely possible to replace the entire HTML on the page, because there's two problems :
- It can be VERY heavy
- There's no way for us to parse the template variables client-side

Number 2 would be your best option of minifying the size of this template.

Ange Tuteur
Forumaster

Male Posts : 13021
Reputation : 2684
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: problem at posting_body adding a Script

Post by Michael_vx on September 1st 2016, 3:37 am

since the Master of Scripts said
- There's no way for us to parse the template variables client-side
i trust what you say
Topic is done
solved to me
Archive it or grabag it Smile
thank you

Michael_vx
Forumember

Male Posts : 655
Reputation : 29
Language : Arabic and some English
Location : Egypt

Back to top Go down

Solved Re: problem at posting_body adding a Script

Post by SLGray on September 1st 2016, 3:54 am

Problem solved & topic archived.
Please read our forum rules: ESF General Rules


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 35670
Reputation : 2375
Language : English
Location : United States

http://fmthemes.forumotion.com/

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum