I just create a custom theme for WordPress and this is my directory.
theme/
-index.php
-header.php
-footer.php
-terms.php
Now I want to make in index.php file have like
Terms
but this doesn't work.
How can I make this when the user clicks terms to redirect him on terms.php file?
actually you should create a Page in your admin menu for Terms and then link what what you want to that Page you created.
but before that I think you should learn more about wordpress and how it manage files and templates.
Related
I want to modify the template of my blog archive page. I want to modify the template file by following the hierarchy of wordpress files, and not to apply a template manually.
I created a page, then set the blog page in the settings> reading. According to the functioning of the file hierarchy, this should use the file archive.php however it is the file index.php which is loaded. Why ?
My wordpress is blank. I just installed the blank WordPress theme JointsWP.
Thanks in advance.
Vince.
If you check the hierarchy more carefully, blog posts link to the index.php, not the archive.php.
i want to convert my html website to the wordpress. But can you please talk me that how i can convert and connect the other pages with the main page???
I'm going to start from the point of view you already have Wordpress and are ready to start.
You can't take your existing HTML website and just add it to WP.
What you need to do is to build your own custom theme, that matches your current HTML files, using the already existing WP templates and files.
Best way is to duplicate an existing theme to play/manipulate so that you don't break WP. The last thing you want to do, having no experience, is to mess with and break the default theme and be unable to get it back again without a full re-install.
RE 'connect the other pages with the main page' WP allows you to have static pages and set them as your home page and/or anywhere else you want. With these pages you can also set up different templates within your theme if you need to.
Wordpress have all this help available here:
Wordpress creating static pages and custom templates
Its not really that simple. You should read about WP theming. Here's the start:
https://codex.wordpress.org/Theme_Development
Check codes from other themes to see how to output basics. Theming has a lot of parts, but to ouput custom html you will need these files:
style.css
functions.php
index.php
single.php
With those you should have an basic blog output with core WP functionality.
I am a real newbie with wordpress. I need to quickly find out the filename for a particular url.
Let's say my URL is
http://example.co.uk/account/membership-levels/
Where will the .php or .html file most likely be? In themes folder?
w
Thanks for your help.
Wordpress doesn't have a 1:1 relation between content and templates. On some minimalist themes you could have a single php template in your themes folder (wp-content/themes/themename/single.php) to display all your articles.
Depending on your permalink structure, that link you are asking about is probably rendered using the page.php template, and if it isn't, then single.php should be the one. The only reason for editing a template is when you need to change the structure of all your posts. If you only need to edit one particular post or page, then you should just edit the content.
To edit the content, you need to log into your dashboard (wp-admin) and look for that entry among the pages or posts section.
Many themes will show an edit icon next to the posts title if you read it while logged on your dashboard, so you can skip searching for it in the backend.
I am new in wordpress and sorry for my poor English.
I want to run the hello.php from input/index.php to input/output/hello.php when the link on index.php was clicked. I have googled it but cannot find the solution ? Any solution for this ?
Log into WordPress
On the left hand menu click "Pages"
Create a page and title it "Hello"
Go into your FTP and into your theme folder: wp-content/themes/your-theme
Open page.php and copy it's code, paste it into a new file and call it page-hello.php
Upload page-hello.php now visit your page your just created.
According to WordPresses Template Hierarchy you can create a page based on the WordPress page slug, all you have to do is prepend page- before the slug.
At first if you are new in wordpress look how you can create theme and how it works(http://codex.wordpress.org/Template_Hierarchy). Then please provide where you have created that directories. Also when you are working in wordpress you have to work only in themes folder and plugins folder you can simply implement it root dir where is you wp-config but I am sure it will not give you the result that you are trying to achieve.
Best Regards,
i'm wondering if it's possible to add a php file in your themes folder (wp-content/themes/classic) where the css file is, then link afterwards? Because i'm currently trying to add a register.php into my blog but i still need the header and everything else.
Yes. For example, if you want something like www.yourdomain.com/test follow this steps:
In your theme folder create a php file called page-test.php.
From your dashboard publish a page with the title Test(with no content at all).
Now, when you'll go to www.yourdomain.com/test you will se your page. And in page-test.php you can use all Wordpress functions such as get_header(), get_sidebar() etc.
Yes. What you want is to define a new "page" template, and then to create a new page in your wordpress using that template. Here's the WP documentation on that topic: http://codex.wordpress.org/Pages#Page_Templates
Alternatively, you don't have to place it in your theme folder; you can put it in the root wordpress folder and have it function outside of wordpress. Then you can change your theme to have a static link to that page, or link to it in some other manner. It would be more difficult to use the header/footer/sidebar template features, though.