Why does "Failed to load resource" text show for "DOCTYPE HTML" tag with "/undefined?235" request in Symfony 2? - html

I've found an error in my Symfony2 website, what you can see below with the link:
https://drive.google.com/open?id=0B430tyHOr_s0SDdFXzJ2T1hVVEE&authuser=0
I use SonataPageBundle and SonataSeoBundle for html rendering, but I don't find the source of this bug.
Could anybody say something for this?
Regards,
Norbert

Related

What is .htmb extension?

Today, I found a web page as following structure. It is just look like a .html page, but extension of that page is .htmb.
http://example.com/name.htmb
I googled also, but I coundn't get any information about .htmb extension.
This appears to be a simple typo! If you change htmb to html, you will see a web page about translation services.
http://www.list.lk/solutions/translation-services.html
It's an extension used in the (abandoned) Lighty2Go webserver, for details see their site:
http://www.lighty2go.com/ (abandoned?)
https://pendriveapps.com/lighty2go-portable-limp-web-server/
Seems to be a Xonobasic executable:
".htmb" => var.l2gDir + "/xonobasic/xonobasic.exe"
as per this post: http://xonocode.com/forum/showthread.php?mode=linear&tid=4&pid=4
HTH!!

How do I link to a downloadable file in CakePHP 3.6?

How do I link to a downloadable file in CakePHP 3.6? The file is webroot/files/filename.pdf
I can create the link using
$this->Html->link('Link text', '/files/filename.pdf');
but when I click on it, I get the message "FilesController could not be found.".
I've searched the documentation and online, but can't find any mention of this.
You need to pass the download attribute in your anchor tag. For cakephp 3, you can pass it something like
$this->Html->link('Link text', '/files/filename.pdf',['download'=>'filename.pdf']);
or
$this->Html->link('Link text', '/files/filename.pdf',array('download'=>'filename.pdf'));
Thanks to David, I realised I was doing the right things as far as Cake was concerned, but was using the wrong file name and linking to a file that didn't exist on the server.

Need to add the requested URL on a "404"-page. [HTML]

If the user tries to access a page which isn't available, he/she is moved to a custom 404.html.
What I'm wondering is if is it possible to access the original requested URL from the custom 404.html, using just HTML? I haven't used PhP or any other side technology.
My code look like this:
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>404 Not Found</title>
</head><body>
<h1>Not Found</h1>
<p>The requested URL was not found on this server.</p>
<p>Additionally, a 404 Not Found
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>
If anyone know how do this, please let me know. Thank you in advance!
Long story short, answer to your question: no, it is not possible to get url by using HTML ONLY, you need to either use client side or server side language.
for example, in javascript, you would do something like this to get previous url,
document.referrer
this would actually be ideal for your scenario, as this work very well, if you arrived at the current page via a link ( not by doing, for example, by bookmark or typing in the address bar).

facebook like button won't "like"

So what's strange is that the like buttons on my site will only work IF the like button has already been liked in the past. If there are no current likes, such as on this page:
http://www.narutomeetsbleach.com/naruto-shippuden-219.html
Then you can click like all you want, but you won't actually like anything. Does anyone know what's wrong? I got my like HTML directly from facebook and it's the exact same as the like buttons that are working.
Thanks so much!
You can use the Facebook LINT tool. It actually checks you meta tags and will point you in some direction what your problem is. (Check link below.. I have added a ?v=1 to the html page to avoid facebook server error response)
http://developers.facebook.com/tools/lint/?url=http%3A%2F%2Fwww.narutomeetsbleach.com%2Fnaruto-shippuden-219.html%3Fv%3D1
Type in your url and check your page.
Try changing your code to the following (is there a reason why you are using the appId/fbAsyncInit methods?):
<div id="fb-root"></div><script src="http://connect.facebook.net/en_US/all.js#xfbml=1"></script><fb:like href="http://www.narutomeetsbleach.com/naruto-shippuden-219.html?v=2" send="false" layout="button_count" width="450" show_faces="false" font="tahoma"></fb:like>
AND / OR
Use this link to generate your LIKE BUTTON Code
http://developers.facebook.com/docs/reference/plugins/like/
Generated Like Button Code (Iframe) :
<iframe src="http://www.facebook.com/plugins/like.php?app_id=137084976372144&href=http%3A%2F%2Fwww.narutomeetsbleach.com%2Fnaruto-shippuden-219.html%3Fv%3D3&send=false&layout=standard&width=450&show_faces=false&action=like&colorscheme=light&font&height=35" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:450px; height:35px;" allowTransparency="true"></iframe>
Found it out! I had to remove the og:type meta tag. Found someone else on google who had a similar problem, that's what he did and now it seems to be working fine for me after I re-linted the url. Facebook's giving me a "warning" because I have og:type missing, but now it's working, so I guess that's all that matters. Thanks for all the help!
reference: Facebook "Like" produces "There was an internal error when updating the Page."
The Facebook button and all it's code comes from them and it's within an iframe with source from their server... you'll have little control over how that works. As long as you got your App ID and such entered correctly... otherwise, you're at their mercy.
Yes, even though it's just a "Like" button, you still need an App ID (appid). More detailed info below...
See the accepted answer to this: "Do I need an appid for the XFBML version of the Facebook Like button?"
And quoting this page, http://developers.facebook.com/docs/guides/web/:
"The JavaScript SDK requires that you register your website with Facebook to get an App ID (or appId). The appId is a unique identifier for your site that ensures that we have the right level of security in place between the user and your website. The following example shows how to load the JavaScript SDK once you have your appId:"

RewriteURL cause chrome Exception

I'm using FormRewriterControlAdapter to rewrite URL
But when I use Google chrome, I had a exception in
Exception:Cannot use a leading .. to exit above the top directory
Stack Trace: 於 System.Web.Util.UrlPath.ReduceVirtualPath(String path)
my web site is http://ranking.heeact.edu.tw
and I've already added
genericmozilla5.browser
Google.browser
Yahooslurp.browser
from
http://todotnet.com/post/2006/07/01/Get-GoogleBot-to-crash-your-NET-20-site.aspx
does anybody know what's wrong?
My got answer.
It's not URL rewriting problem. Just a asp.net control menuitem cause Chrome render html tag cuase exception.
http://www.google.com/support/forum/p/Chrome/thread?tid=7506cca26ec06af7&hl=en