I have a website which is developed using Joomla. I am using Joomla's Default URL rewriting option.
On one page I have this URL before SEF enable.
index.php?option=com_osproperty&task=property_details&id=19
after SEF Enabled it becomes..
component/osproperty/?no_html=1
I want to skip this URL to become SEO Friendly. Because due to this, I am not able to use print functionality.
The router.php file for your com_osproperty is not properly written to address print links. You will need to fix that file. Take a look at how the com_content router is written.
Related
I have a Wordpress blog installed in a subfolder and I would like to replace a part of the url of the post.
Right now it is like this: http://domain.com/wordpress/{permalink-structure}
What I would like to achieve (without moving the site) is: http://domain.com/{permalink-structure}
I tried changing the site url (and followed the instructions provided by WP on how to do this), but if I do this, my front-end stops working ( I am not retrieving the posts etc through the WP-API and I work with AngularJS)
Is there an easy way to automatically modify the (by wordpress generated) url of all future posts by using a plugin or modifying the source code? Or via .htaccess?
Redirecting via htaccess is my preferred option but when I tried this, the wp-api plugin (accessible via domain.com/wordpress/wp-json/* stopped working
Just to be clear: I am not accessing the posts by the generated URLS, I retrieve them via the API and the only thing I want is that the link object in the retrieved post has a different URL.
I don't know. Just try to help. This is my solution redirect what need to redirect.
Options +FollowSymLinks
RewriteEngine On
RewriteRule ^wordpress/wp-json/(.*)$ http://domain.com/wordpress/wp-json/$1 [R=301,NC,L]
RewriteRule ^wordpress/(.*)$ /$1 [R=301,NC,L]
you want to change wordpress domain or URL. you need to perform following steps.
1 you need to modify all url's stored in database. I prefer to use https://interconnectit.com/ tool. It is pretty good and easy.
2 Once you update all database urls then you need to login in wp-admin and just update permalink settings.
you need to check plugins too. Some plugins may get deactivated you need to activate them again.
Hope this will help.
check word press codex:
https://codex.wordpress.org/Giving_WordPress_Its_Own_Directory
you can display your word press without move your directory from sub folder to root folder and can remove sub-directory from URL.
I am trying to make a website with joomla 2.5.
Now I want to do something that the urls do not change at all.
I mean that I want that the browser address bar just show the name of the site in all of the pages.
Is there any extensions for it?
EDIT
Now my urls look like the following:
mysite.com/component/k2/66-n-t-shirt-49-detail?Itemid=0
and I want it to be like this:
mysite.com/t-shirt1
Is it possible to change it from htaccess file?
I have changed the htaccess.txt to .htaccess too but it didn't work and it just removed index.php from the url.
Wrap your site in an iframe or frameset, that will only show the frameset url.
Else you could change all the urls to post, but this will require quite an effort in jQuery and would be quite hard.
I have a perfectly good (so far) setup of wordpress of for a new website. The pretty urls are working as expected.
I have 1 dynamic page that loads content depending on the querystring:
/dynamic/?loc=england&code=uk
I wish to make this URL "pretty" as well but every-time I modify the .htaccess no changes are made. Tried everything and googled everything else - last resort. If I could get the following to work then I would be happy.
I need to make the URL look like.
/dynamic/location/england/code/uk/
Adding this to any .htaccess breaks the whole website.
RewriteRule /dynamic/(.*)/(.*)/(.*)/(.*)/$ /dynamic?$1=$2&$3=$4
What am i missing.
Thanks in advance
N
Don't add the rewrite rule to your .htaccess file. WordPress manages that file for you, so try to use built-in features whenever you can.
WordPress actually has a somewhat advanced rewrite engine that ships standard - and it's pluggable just like the rest of the platform.
The trick, though, is working with it. You'll need to register your RegEx so WordPress knows what kinds of strings to match (i.e dynamic/location/(.*)/code/(.*) => /dynamic?$loc=$1&code=$2). Then you'll need to set up the page and script on the back end to handle the submission.
For a similar example, look at the answer I received to parsing custom URLs with a custom post type over on WordPress Answers. Extending this, you'll need to set up code similar to the following (note: untested!!!):
<?php
add_action('init', 'add_my_rewrite');
function add_my_rewrite() {
global $wp_rewrite;
$wp_rewrite->add_rule('location/([^/]+)/code/([^/]+)','index.php?loc=$matches[1]&code=$matches[2]','top');
$wp_rewrite->flush_rules(false); // This should really be done in a plugin activation
}
This should add the rewrite structure to your .htaccess file automatically.
I made a component and now I want to customize the link for it.
I already wrote the router.php.
The link to the component view (if I use the JRoute function of course) now looks good, except for the first part, which looks like :
http://www.example.com/en/component/componentname/...
don't mind the "en", it's there cause I use JomFish to manage more languages on my site.
I want to transform "/component/componentname/" to "/myString/" for example.
I can't use the menu for this, cause my site displays info from a database, linking this many sites to my menu is impossible.
The only solution I found requires the changing of the Joomla JRoute function (I found only a suggestion, not how it's done :( ).
What about using mod_rewrite to rewrite your url?
Basically you put the rewrite rules into your .htaccess file and Apache will handle the rest.
There is a great guide that teaches you all about it on http://www.htmlist.com/how-to/a-simplemod_rewrite-tutorial/
I have made a joomla component and wise to make the site sef. The problem is that some of the URL from the components put values by get method. so that the next page can do the task accordingly.
say
index.php?option=com_mediaonline&view=mediaonline&task=234&id=837
so that the next page will process the task accordingly, with task = 234 and id = 837. If i try to make it sef urls then nothing will work properly.
Is there any sef components or other extension available to solve this issue.
The best component for this is sh404sef, look for it in extensions.joomla.org and making the sef file for your component won't take more than 2 days
Have you not considered writing your own using a router.php file?
http://docs.joomla.org/Routing
Although sh404sef is useful I've found ACEsef to be better.