Google docs viewer not working - google-docs

Using this code:
<iframe height="780" src="http://docs.google.com/viewer?url=http://ruh.kz/sites/default/files/doc/ritorika.pdf&embedded=true" style="border: none;" width="600"></iframe>
But all the time im getting this annoying message:
Sorry, we are unable to retrieve the document for viewing or you don't have permission to view the document.
By the way, i have read about ISP might block google docs. But i've checked another sites with google docs viewer and they seemed to work perfectly.

to embed your pdf without putting it in your server , just login to your gmail and upload it in google docs then copy the link and put it in your iframe's src

first you try with online version to view your file if it shows your file,you gave wrong url to iframe,if viewer does not show your file at embedded version and online version check your file size,file url and file permissions to viewer can reach your document.You can try your url, for example http://www.foo.com/bar.pdf paste in your browser,if url is right browser shows the file...

Related

href pdf file url is not found when click on it

I'm working on the vuejs application and, I'm receiving the pdf file from node backend which has the eg url https:abc.com/api/filename.pdf.
I'm using it link so
const myUrlVariable='https://someurl.com/dataCollection/imperial'
<a :href="myUrlVariable" target="_blank"></a>
The requirement of this is to when user click on link, file should open in the new tab.
But Right now when I click on the link its considering it as application route and show the message page not found, instead it show the pdf file.
I check this link in the postman and its returning the file as expected.
href should not be a string, but a binding to a variable
Change this
to this
<a :href="myUrlVariable" target="_blank"></a>
👆
Is the url correct?
https:abc... -> https://abc...

Google Site Verification Failure - HTML File Upload method

I have an Express/NodeJS app running on Google App Engine, for which I have the URL in the format of:
project-name.appspot.com, where project-name: My google project name
Now, for site verification, I am using HTML File Upload method.
I am serving the html verification file provided by google as follows:
res.sendFile(path.join(__dirname, path_to_html_file))
Now, when I enter the url: https://project-name.appspot.com/, I can view the file.
Also, the file has the same name as provided by Google.
However, when I click Verify in Webmaster, it still fails with error message "File not Found"
Can anyone point what I might be doing incorrectly ?
You need to serve this file from the /xxxxx.html url, not the root url.
In other words, it needs to be accessed from https://project-name.appspot.com/xxxxxxxx.html
Think about it... This file must stay up for as long as you want to be verified, so it doesn't make sense to be shown at the root url.
Also, make sure there are no redirects in serving this file.

How can i give link to download(not open) pdf file in reactjs

this is my code which i am writing in render method, which works fine, but instead of downloading this file it's opening in browser.
download
How can i give a link in react to force download a file, file which is coming from external server.
HTML5
<a download href="file.pdf">Download PDF</a>
Suppose you have a variable names as "link" in which the link is stored. So you can do,
<a href={`${link}`} type="application/pdf; download='some_pdf_name'>Download</a>

Codeigniter Controller class login form : 404 page not found

Im trying to combine several tutorials about Codeigniter and bootstrap and understand per codes so i can integrate it in my project. What i am trying to do right now is create a login form using the two framework.
And i setup my View according to the turotial included in Codeigniter 'user_guide/tutorial/static_pages.html' which my landing page is named as 'home.php' is inside the folder 'pages' and header.php, and footer.php is inside the 'templates' folder. I created also a controller: Page.php.
I also use .htaccess to hide 'index.php'. Now i follow this tutorial how to create a login page:
http://learnjquerybootstrap.blogspot.com/2015/01/login-session-using-codeigniter-and-bootstrap.html?m=1
-the only difference is this since i use htaccess:
<?php echo form_open(clogin/index); ?>
But when I try to submit the page i receive a: 404 page not found.
My navbar links are working fine. I understand that the codeigniter works like this:
http://localhost/myfolder/index.php/class/function/
so when i submit my form the url that show up is:
http://localhost/myfolder/clogin/index
and gives me: 404 page not found.
Question:
What is wrong with it?
is there something wrong with the tutorial that i am using? i check other tutorials and the controller structure is just the same, like on this link:
http://www.kodingmadesimple.com/2014/08/how-to-create-login-form-codeigniter-mysql-twitter-bootstrap.html
do i need to include clogin.php in route.php?
or is it about the htaccess? my
uri_protocol
is configured as
'REQUEST_URI'
in config.php. i tried other options but still the same.
Don't need include to route.
I recommented ready auth library.
If you use DevTools in your browser maybe "Network" tab of devtools can help you to why you get 404 error.
i already firgured it out.The mistake was in the route.php, since i tried to combine two examples.. i realized that the wildcard route that i included from the Codeigniter user guide will not work with the Clogin.php.
Since it was set as
$route['(:any)']='pages/view/$1';
So the url works as
http://localhost/myfolder/pages/view/clogin
instead of
http://localhost/myfolder/clogin.
I removed it and now it is working.

pmwiki+ iis+ fastcgi Permissions partially dened

Recently ,I meet a problem ,that deploy pmwiki on our iis server,all things goes well.However,the problem occured,that ,our pmwiki has six group ,as we all know that,wiki must allow people to edit it content,the directory is like this:
![enter image description here][1]
the problem is that,I can change the defualt page ,howerver,can not edit the Group1~Group6 folder.
the iis setting is like this:
IE browser :http://your.domain/Group2/?n=Main.HomePage?action=edit
then the browse occured error:HTTP ERROR 405 POST DID NOT ALLOWED
how can I solve this problem ?
![enter image description here][2]
when i want to change the content of everygroup ,for example:
After F12 chrome debug, I found that it did not support HTTP POST method!

Resources