URL length problems on iFrame - url

Hello everyone I'm having some problems when a calling an iframe that has an specific URL length: The complete URL is as follows:
http://localhost:8080/autorizaciones/pages/administracion/autorizaciones/solicitarAutorizacion.jsf?nkttxms=6175141345567386080&nosjxms =%7B%22formActionURL%22%3A%22crearCotizacion.do%22%2C%22renderSection%22%3A%5B%22%27div_pagina%27%22%2C%22%27mensajes%27%22%5D%2C%22formName%22%3A%22cotizarRecotizarReservarForm%22%2C%22loadMenu%22%3Afalse%2C%22scriptParameters%22%3A%7B%22evalScripts%22%3Atrue%7D%2C%22viewParameters%22%3A%7B%22autorizaciones%22%3A%22%5B%7B%5C%22codigoSistema%5C%22%3A%5C%22SISPE%5C%22%2C%5C%22descripcion%5C%22%3A%5C%22Solicito+autorizacion+descuento+variable+del+5.0%25+para+la%28s%29+clasificacion%28es%29%3A+2226-PAVOS+CONGELADOS+%5C%22%2C%5C%22areaTrabajo%5C%22%3A%5C%22MULTICENTRO%5C%22%2C%5C%22tituloAutorizacion%5C%22%3A%5C%22AUTORIZACION+DESCUENTO+VARIABLE+GERENTE+COMERCIAL+5.0%5C%22%2C%5C%22filtroTipoAutorizacion%5C%22%3A%7B%5C%227%5C%22%3A%5B%7B%5C%22codigoComponente%5C%22%3A23%2C%5C%22valorComponente%5C%22%3A%5C%225.0%5C%22%2C%5C%22soloLectura%5C%22%3Atrue%7D%5D%7D%2C%5C%22filtroUsuariosAutorizadores%5C%22%3A%5B%5C%22FRM1458%5C%22%5D%2C%5C%22dataKeys%5C%22%3A%5B%7B%5C%22label%5C%22%3A%5C%22AREA+TRABAJO%5C%22%2C%5C%22value%5C%22%3A%5C%22101%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%2C%7B%5C%22label%5C%22%3A%5C%22NUMERO+PEDIDO%5C%22%2C%5C%22value%5C%22%3A%5C%22%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%2C%7B%5C%22label%5C%22%3A%5C%22TOTAL+PEDIDO%5C%22%2C%5C%22value%5C%22%3A%5C%22925.6999999999999%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%2C%7B%5C%22label%5C%22%3A%5C%22VALOR+APLICAR+DESCUENTO%5C%22%2C%5C%22value%5C%22%3A%5C%22253.4%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%2C%7B%5C%22label%5C%22%3A%5C%22NUMERO+DOCUMENTO%5C%22%2C%5C%22value%5C%22%3A%5C%221104627169%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%2C%7B%5C%22label%5C%22%3A%5C%22NOMBRE+CONTACTO%5C%22%2C%5C%22value%5C%22%3A%5C%22OCHOA+VASQUEZ+PABLO+IVAN%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%5D%2C%5C%22secuencial%5C%22%3A1%7D%2C%7B%5C%22codigoSistema%5C%22%3A%5C%22SISPE%5C%22%2C%5C%22descripcion%5C%22%3A%5C%22Solicito+autorizacion+descuento+variable+del+5.0%25+para+la%28s%29+clasificacion%28es%29%3A+1602-CANASTAS+%5C%22%2C%5C%22areaTrabajo%5C%22%3A%5C%22MULTICENTRO%5C%22%2C%5C%22tituloAutorizacion%5C%22%3A%5C%22AUTORIZACION+DESCUENTO+VARIABLE+GERENTE+COMERCIAL+5.0%5C%22%2C%5C%22filtroTipoAutorizacion%5C%22%3A%7B%5C%227%5C%22%3A%5B%7B%5C%22codigoComponente%5C%22%3A23%2C%5C%22valorComponente%5C%22%3A%5C%225.0%5C%22%2C%5C%22soloLectura%5C%22%3Atrue%7D%5D%7D%2C%5C%22filtroUsuariosAutorizadores%5C%22%3A%5B%5C%22KFLOW100%5C%22%5D%2C%5C%22dataKeys%5C%22%3A%5B%7B%5C%22label%5C%22%3A%5C%22AREA+TRABAJO%5C%22%2C%5C%22value%5C%22%3A%5C%22101%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%2C%7B%5C%22label%5C%22%3A%5C%22NUMERO+PEDIDO%5C%22%2C%5C%22value%5C%22%3A%5C%22%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%2C%7B%5C%22label%5C%22%3A%5C%22TOTAL+PEDIDO%5C%22%2C%5C%22value%5C%22%3A%5C%22925.6999999999999%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%2C%7B%5C%22label%5C%22%3A%5C%22VALOR+APLICAR+DESCUENTO%5C%22%2C%5C%22value%5C%22%3A%5C%22600.3%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%2C%7B%5C%22label%5C%22%3A%5C%22NUMERO+DOCUMENTO%5C%22%2C%5C%22value%5C%22%3A%5C%221104627169%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%2C%7B%5C%22label%5C%22%3A%5C%22NOMBRE+CONTACTO%5C%22%2C%5C%22value%5C%22%3A%5C%22OCHOA+VASQUEZ+PABLO+IVAN%5C%22%2C%5C%22hasAction%5C%22%3Afalse%2C%5C%22isVisibleInManageTaskDescription%5C%22%3Atrue%7D%5D%2C%5C%22secuencial%5C%22%3A2%7D%5D%22%2C%22backgroundColor%22%3A%22%23F4F5EB%22%2
I know that it has a lot of data on it's query string, and that I should use POST when transferring large quantities of data. However, that's the way the system creates them... that was already done before I found the problem.
The main problem is that a lot of modules have dependencies on this, and changing it would make it impossible to accomplish deadlines (next week).
Now we use that URL in the following iframe:
<iframe name="Contactos" width="100%" height="100%" align="middle" class="tabla_informacion" src="urlAbove" frameBorder="0">
</iframe>
However when the frame appears it just shows a blank screen, no callbacks at all are triggered on the server....
Now if we reduce the url length it works correctly. At first glance I thought it was a problem related to header lengths on jBOSS AS 6 (by default 8KB), so I changed it on the server.conf file and increased it to 64KB. No luck at all...
But then when I used Firefox's Poster plugin to create a GET request with the whole URL, it worked correctly and server breakpoints where triggered, meaning that it's not a server's problem, at least at the current URL length....
Maybe is a browser limitation? (We are using Internet Explorer...) is it a know problem? Or maybe there is something that I'm missing when calling iFrames?

It's quite possibly a browser limit. The fact that the page loads (or at least the request gets to the server) in Firefox is a good hint.
Your URL is 4,097 characters, and the limit in IE is 2,083.

Related

Why the url of youtube will be changed when I hover mouse on a video?

I was surfing on youtube and I realized something.
When I hover mouse on a video, then the url will be changed.
Interestingly, this happens in some browsers.What's the matter? Why does string start with &? https://www.youtube.com/?&ab_channel=NASA
What is the benefit to change the URL?
Interestingly, this happens in some browsers.
Different browser different support, a what you see is what you get is a standard we all want and must write our scripts specific to each browser if a feature requires it. In this case the new feature may not be widely supported or their coding wasn't compliant enough to give you this exact result each browser.
What's the matter?
No problem here, the URL is a tiny-bit broken but won't impact site performance unless you happen to error out the server and crash the entire network.
Why does string start with ?& https://www.youtube.com/?&ab_channel=NASA
What is the benefit to change the URL?
A URL alone has no parameters passed to it, so youtube.com. When a parameter is passed through the site on its HTTPS request will check these and determine what it is you want. So the response will return NASA cause ab_channel included it.
Because ? has nothing after it like ?video=asd89sa982 it's treated as undefined and serves no value or importance.
YouTube can fix it if they desire with script adjustment.
the URLs works in a way that when the site has started or reloaded, It's going to check for any element that has a href which has a link that has either https://www.youtube.com/watch?v= or https://youtu.be/ basically a YouTube video and then save those links, when one of them i hovered over, It's tell which. This works fine but one downside that I'm currently facing is that new links that are added in after the site has already started or reloaded won't be counted and therefore when I hover them it won't show the links, I'm reffering to comments; for-example if I make a comment that has a link to a video, after i post that comments and hover over that link I posted, It won't show the link. I could make a function which reloads every like 5 seconds but this doesn't seem to be a good idea. Plus what I'm actually working on, realoding every time won't be good.

Any way to force webpage to print exactly as it looks in browser?

I am looking for options on how to deal with an issue as I don't think there is an easy fix.
We're dealing with a really stubborn client that doesn't want to accept the fact that browsers don't print css backgrounds by default.
He's convinced that XP running IE 6 & 7 are the most common browsers and we are a bad company for not supporting them. (I've shown him analytics from our typical client's visitors but it hasn't changed his mind). I'm rewriting his site to work on them but am stuck with the print stuff now.
He would like (demand is a more accurate term) to have the page print exactly as it looks on the site as well as them look exactly the same in all operating systems & browsers. I don't think it's feasible to go through and put all the images in the html instead of in the css and I've tried the list-style tip without luck. Lots of the color of the site comes in from background css colors as well.
Is there any other options? Or even suggestions on how to deal with this client?
Try something like:
<style type='text/css'>
#import 'whatever.css' screen, print;
</style>
Make sure #import is above all other CSS tags, and that you target the external stylesheet that you have your CSS for your page on.
Here's a slightly different approach:
I would consider converting the web page to a pdf which you can print instead.
An nice way to do the conversion is through a product called PhantomJS. It's essentially a headless browser that will render the page and convert it to a pdf on the fly. You can integrate by running the PhantomJS server and add a link on the original page to download the pdf.
The pdf will then print the page consistently across all browsers. There is however a decent amount of additional work, so you have to consider if it's a good fit for your needs and timeline...
Additional complexity with this solution is that you have to host the PhantomJS javascript server somewhere, write a PhantomJS script using the API to convert your page to pdf.
Pdf and image conversions are relatively easy to do, but you have to also consider authentication if your pages require login. PhantomJS will write the converted file to disk on the server, so you would also have to manage downloads to the user's browser.
All in all it's a good chunk of work, but you might find it interesting to at least learn about it :-).
More info here:
http://phantomjs.org/

Prevent URL being stored to browser history

I need to open a popup window to a url with certain parameters. The parameters contain information that I would like to prevent from showing up in the browser history. The url points to a 3rd party site and I can't affect the way those parameters are transferred to them (can't use POST for example).
Currently I have worked around this so that I have a page on our server that loads the content of the third party page to an iframe and this seems to work.
However, I was wondering if there are any other ways of doing this and are they maybe somehow better or worse? Javascript or something? The negative side of this iframe thing is that it is not XHTML Strict compliant, which is something we are aiming for.
There are other similar questions here but I couldn't find a good answer.
Edit: Apparently this does not work as expected in IE. It might be that I still keep the solution for another reason, but it would be nice to know if there is a "bulletproof" solution.

rails page won't display entirely

I'm having the most peculiar problem, and I was hoping I someone could point me in the right direction on how to address it (or even locate it...). I'm working on a rails site, and the pages display in most browsers without any issues. In others (AOL, IE 6 - 7, and some of the other lesser used ones) the page will load, with all of the correct formatting, but completely missing the inside content.
For example, the site uses a traditional online store format, but will load the name of the site, the name of the product, and the page footer, but not the description or images. This issue has been reproduced on several computers, but I can't figure it out at ALL.
Thanks for any help!
My approach to this sort of problem would be to use the browser to get the html you are trying to render (in firefox, View>>Page Source), and saving it as a static html file. Then you can fiddle with this file one piece at a time until you figure out what's throwing IE for a loop.
If you view the page source is the data you are looking for included? This can help you figure out if you have a formatting issue on the client side or a data generation issue on the server side.

sifr3 - prefetch not working?

I am having a problem with the loading times/size of an sifr 3 enabled site, and found out the the font swf is requested several times in my application. This can be seen in the network tab of firebug, as well as in the apache logs.
On http://novemberborn.net/flash/prefetching-movies there are some instructions for prefetching. However that does not work, the prefetch Method is not available (still in the docu!). I understand that prefetching is done automatically, however that does not seem to work.
Even in the demo page of the sifr download package, with an empty browser cache I get several hits for rockwell.swf and cochin.swf! Both with Firefox 3 and IE7...
Any chance for an easy and quick fix?
Greetings,
Simon
Fundamentally, this is an issue between the browser and the Flash player. As sIFR inserts the Flash movies into the page, the browser initializes the Flash plugin with the path to the Flash movie. If the movie is not yet in a local cache, it's requested from the server. Since the movies are inserted within a few milliseconds, this would mean that a request is made for each inserted movie.
sIFR tries to prevent this by prefetching the Flash movies. It does this ones per browser session, based on a session cookie. This merely fires off a request for the movie file, and hopefully that file is in the cache by the time replacement starts. Therefore its important to load the sIFR JavaScript code as early as possible, and to activate sIFR properly by passing the Flash movies to the sIFR.activate() method.
In my experience the only way to reliably test this process is clearing browser cache, closing all browser instances (to get rid of the session cookie), then opening the browser and going straight to the page you want to test. I don't find the activity monitors within browsers reliable, so either check through an HTTP proxy or the server logs.
The one remaining improvement I could make is to try and detect the progress of the prefetch, and hold off on replacing elements until the prefetch is complete.
Do you have the option to move to Cufon? You'll find it much easier to use and isn't quirky.

Resources