WPML + Woocommerce Product 404 Page Error - http-status-code-404

http://profaj.org/armell/product/granul-dolum/ 404 page
but other languages are working;
http://profaj.org/armell/en/product/granule-filling/
where is the problem?

try this, I had the same problem and it worked for me:
1, WPML -> String Translation -> Search 'URL slugs -'
2, put the slug of your shop and products
3, Check 'Translation is complete' and click 'Save'
source: http://wpml.org/forums/topic/translated-woocommerce-product-category-slugs-broken-404-2/

Related

Sveltekit Dynamic Routing

I'm attempting to create a details page with dynamic routing. My general routes look like this:
src /
routes /
products /
[id].svelte
index.svelte
When I try to load http://localhost:3000/products/1234 I get a 404 and I'm not entirely sure why. Looking through the docs shows this should be valid.
This is the error I get:
Not found: /products/123
Error: Not found: /products/123
at resolve (file:///C:/projects/sveltekit/ecommerce/node_modules/#sveltejs/kit/dist/ssr.js:1824:14)
at async Object.handle (c:/projects/sveltekit/ecommerce/src/hooks.ts:8:14)
at async respond (file:///C:/projects/sveltekit/ecommerce/node_modules/#sveltejs/kit/dist/ssr.js:1760:10)
at async file:///C:/projects/sveltekit/ecommerce/node_modules/#sveltejs/kit/dist/chunks/index.js:4374:24
EDIT: The route /products works as expected.
A silly typo is what caused all of this in my source. Nothing more. product != products for future reference.

Cannot display image from backend express react

I'm having a backend server with an upload folder directly in the root.
In my backend, http://localhost:4000, I have my upload folder and I'd like to display the image that matched the url given for each element I have in my backend :
const url = "http://localhost:4000/"
{filteredDrawings && filteredDrawings.map((drawing) => (
etc...
<div className='cardimage-container'>
<Card.Img variant='top' src={`${url}/${drawing.imageLink}`} />
</div>
When checking my browner, i have src="upload/testupload.jpg" displayed as src of the image but I have nothing displayed
I wrote app.use("/upload", express.static(path.join(__dirname, "../upload"))); in my my backend app.
When I try http://localhost:4000/upload/uploadtest.jpg, I have "Cannot GET /upload/uploadtest.jpg"
Thanks in advance
Ok problem solved, the issue was the quote not being ' but `
app.use(`/upload`, express.static(`upload`));
the error you faced is because the route /upload/uploadtest.jpg is not defined well as a route in the nodejs , you should read the document based on id or other identifier and return as a binary.
as for react try {{ }} without $
in this case it should be worked without any problem

Remove L parameter in request URL

I'm using Solr extension with TYPO3 9.5.3 and I couldn't index the Pages, I get this error https://imgur.com/1e6LfIy
Failed to execute Page Indexer Request. Request ID: 5d78d130b8b4d
When I look at the Solr log, I see that Typo3 add &L=0 to the request URL, the pages with &L=0 return '404 page not found' error :
request url => 'http://example.com/index.php?id=5&L=0' (43 chars)
I added the following code to my TS setup, But that did not work and the request url always ends with &L=0
plugin.tx_solr.index.queue.pages.fields.url.typolink.additionalParams >
I'm not sure that's the only reason solr doesn't index the pages (news can be indexed without any problem), but first, how can I solve the problem and remove &L=0 from request URL in Solr ?
Can you check your TypoScript if you have a configuration like
config.defaultGetVars.L = 0
or if other old language settings exist
I
m not dure, but have you an older languge-Configuration where you Deine the language-Parameter deines?

Single page addition to 'singlepage' website not working

I might be asking a stupid question but I've spent days on stackoverflow and git as well as Hugo's official documentation and I've gotten 15 different ways of doing something and nothing seems to work.
I have a 1 page hugo website and I want to add in a privacy policy.
Within the root/config.toml I have the following:
[[params.footer.quicklinks]]
text = "Privacy Policy"
link = "privacypolicy.html"
Within root/content I have a file called privacypolicy.md with the following:
---
title: "Privacy Policy"
type: page
page: "privacypolicy.html"
---
Within root/layout/page I have privacypolicy.html
When I click the link on the core page to go to the privacy policy I get a '404 page not found'
Fix the typo layouts. Put the privacypolicy.html file in root/layouts/page dir.
Create a new page dir and put the privacypolicy.md in root/content/page.
Use Url tag in md file like this:
---
title: "your title"
type: page
Url: page/privacypolicy
---
Your content here...
This will open in your http://baseUrl/page/privacypolicy. Recommended to rerun hugo server and hard refresh(ctrl shift R) web pages.

My osclass links are working properly but returns 404 error when checked

I have created used car website www.carsangrah.com using osclass.
Some links (http://www.carsangrah.com/buy-used-cars_maharashtra-r781510) are working perfect but returns broken link (404 error) when checked on http://validator.w3.org/checklink.
Google and Bing webmaster also showing as 404 error. I am not able to index these links in Google and Bing. Please suggest a solution.
Thanks
Here is the solution got to oc-includes/osclass/controller then search.php then find this
if( count($aItems) === 0 ) {
header('HTTP/1.1 404 Not Found');
}
replace if( count($aItems) === 0 ) with if( count($aItems) === -1 ).
that fixes
Osclass by default if a search have 0 results it returns 404 status code, you don't want to search engines index pages without any useful content.
If a link, results on a search results page with listings, 200 status code is returned.
Ah that explains the 404 issues I am seeing. I am going to log this as and error as no listings returned does not mean 404 it means no listings. 404 is page not found which is clearly wrong as the server is delivering a html page from the server.

Resources