I am trying to install Wordpress using this tutorial https://cloud.google.com/community/tutorials/run-wordpress-on-appengine-standard.
I have it deployed, but when I try to have it as "subfolder" /blog service of the main domain using dispatch.yaml, the site seems to load (e. g. file /blog/2021/05/27/hello-world/), but the css and js files throw 404 error.
E.g. /blog/wp-includes/css/dist/block-library/style.min.css?ver=5.7.2.
I have also changed siteurl in the database, but that does not seem to work.
Check your static file handler in app.yaml. Since you are putting your site under a folder (sub folder), calls to your static files start from /blog/. This means the handlers for your static file should also start with /blog/
Related
I explain you my situation,
I have a website that we'll called website-a.com that is link to my personal project.
On this project, every users can have a page, with the url my-project.com/[username]. So the urls will then be my-project.com/user1, my-project.com/user2, ...
For the context, I'm building it in Next JS, with the following code architecture :
--
pages
-- [username]
-- index.tsx
-- about.tsx
--
And I'm using Nginx with pm2 and a proxy pass that points to my http://localhost:3000
Now, I'd like to redirect a second domain name to a specific page of a user.
So I would like that when I go to user1.com, it displays my-project.com/user1 without modifying the url.
I pointed the DNS of user1.com to my server, I created a new host nginx and I made a proxy_pass to http://localhost:3000/user1. It's working, but I don't have the ressources css and js, because next is trying to load them from user1.com and they don't exists (user1.com/css/abc.css, ...).
I also tried to modify the build-manifest.json in the .next folder created after the build and it didn't work
So either I would like to find a way for Next JS to take the resources from my-project.com even if it is on user1.com (let it be an absolute path), or put a configuration with the nginx host but I don't don't know which one.
Thanks you for your help
I installed WP locally on XAMPP.
When I manually type my project root in a browser I start seeing this. But when I run the project through VScode Live server I start seeing all files and directories of my site see here.
Why does this happen? Is it because I run the project locally? Or is it because the root is followed by :5050 port number?
My theme style.css is empty.
My theme index.php contains only starting html !+tab attributes (see here)
The first image looks like to be served by apache which loads mod_php which "executes" the php code of every .php file and serve the result as html.
The second image looks like an application running on port 5000 (which might not be apache) and NOT using a module to "execute" .php file so it just shows the content of the folder.
This can be a silly question but I have had some issues with it. I am trying to implement jwplayer with meteor. Jwplayer will try to get a file based off the url you suggest. So I tried to place a file in localhost:3000/test.mp3. When I tried to hit that url I get just the default site. This would work if I used tomcat. Is there something I can do to get the files relative to meteor directory?
Thanks for your help.
In the /public directory, per the docs:
Lastly, the Meteor server will serve any files under the public directory, just like in a Rails or Django project. This is the place for images, favicon.ico, robots.txt, and anything else.
Meteor hasn't yet implemented server side routing and all directories are ultimately flattened. So for the time being, you can access your file at http://localhost:3000/test.mp3, but that may change in the future.
I have recently configured a wordpress site using a VPS setup with LEMP. I'm new to nginx so I'm using an nginx config I found here.
Anyways, I'm using the jQuery file upload tool and I have it setup to where it uploads the files (images in this case) to a couple directories (php/file and php/crop) on upload.
When using the Delete button, The delete function is passed the URL (example.com/server/php?file=image.jpg) hitting the index.php which takes the delete request and deletes the images in the directories associated.
However, when I enable 'dav_methods PUT DELETE MKCOL COPY MOVE;' in nginx, the delete request deletes the directory.
How do I make it where it hits index.php so that I can let it delete the files in the proper directories?
I have symfony web files in web root folder where the project is running. I have site files such as index.html, aboutus.html and contactus.html files. I have put these files into public_html/site/ How to access these files by default using routing.yml? also project should run in index.php
Hm...If you want to add to your project some static pages, I would recommend you this method.I think this is the right way. For index.php ,well read this
Why don't you make a new module for static pages and move the html content into it?
You have to understand that routing system in symfony is used for connect requested urls to controllers. So you can't use it to provide generating urls for static pages outside of your symfony application. That files are just like files of foreign site.
So you can just use link_to('about us', $this->getRequest()->getHost().'/about_us.html');