The 32K Limit and How to Work Around It

PowerSchool has a limit of displaying 32,000 characters for a student page. The limit, often referred to as the 32K Limit, is how many characters are displayed when the page is rendered (viewed in the browser with actual data) rather than the actual file size. When the limit is exceeded, then the page quits working correctly. For example, say you created a page showing lots of demographic information for a student. When you view it for one student, everything looks okay, but when you view it for a student who has more data, there are problems with the page, such as left and right arrows where you have drop-down menus, or problems with the header and footer area. The reason for the problems is that the student who has more data has exceeded the 32K limit. The page limit is one reason why there are so many student pages.

To get around the 32K limit, you'll either need to divide the page up and make more than one page, or make more than one page and use the x:insertfile command to merge them together so they appear as one page. You can find examples of pages that use the x:insertfile command on the server, such as the emergency page in the admin/students folder and other pages that insert state specific data onto the page, but here are the basics on how it works:

1. Create a new html page and cut and paste part of the contents of the original page onto it. Do not cut any header or footer information - just content.

2. In the original page, insert an x:insertfile command where the content use to be so that it displays that content in the browser with the original page.

For example, if the original page is named bigdemographicspage.html and the second page is called bigdemographicspage2.html, then the insert command on the original page would look like the following: ~[x:insertfile;bigdemographicspage2.html]. You can have multiple insertfile commands on a page.

One thing to keep in mind is if you're using the x:insertfile command on custom screen html pages located in the admin/students/studentpages folder, you will need to put the file it references into a sub folder so that page does not appear in the custom screens menu too. For example, if bigdemographicspage.html is a custom screen html page, then put bigdemographicspage2.html in a subfolder and change the insert command to ~[x:insertfile;subfoldername/bigdemographicspage2.html]. Or you can leave them in the same folder and add (less than)!--NoLink--(greater than) in the HTML code at the top of the bigdemographicspage2.html page and that will keep it from appearing as a link in the menu. Replace (less than) and (greater than) with the actual symbols - this site doesn't show them when typed.

Another thing to keep in mind is if you're using an image server, there's a lot of extra html added to a rendered page compared to not using an image server. If you're using a test server without an image server and the page looks fine on it, but doesn't work right when you place it on your production server which is using an image server, then the extra html from the image server is likely causing the page to exceed the 32K limit. Also, when an upgrade comes out, additional code may have been added to the wildcards used on most admin pages, which could push the page past 32K. If you look at the actual file size of your page, it's good to keep it in the low 20's to account for the data and wildcard information that will be added when the page is viewed.

One last thing to keep in mind is the workaround only works on admin pages. If you're creating a custom page for the guardian portal and it's too big, you'll need to break it into smaller pages and link to each one individually.

0
Your rating: None

Comments

Does runreports.html need wc:commonscripts?

My runreports.html is beyond the 32K limit, and a quick solution is to remove wc:commonscripts, as I can see no need for it on this page. Am I overlooking something? Anyone running runports.html without wc:commonscripts?

Re: Does runreports.html need wc:commonscripts?

What version of PS are you running? In 6.0 the reports list was all changed around with tabs and is now much smaller. The old pre 6 runreports.html doesn't use the commonscripts, but I believe 6+ does.

Syndicate content Syndicate content