Wordpress website working fine on localhost but not displaying front pages on webhost

The website works perfect on my localhost. I used duplicator plugin to upload it on my web-host. Database connections are established since mywebsite.com/wp-admin works perfect. I can login the wordpress wp-admin panel and all the plugins, pages, posts are there and are editable. Also the permalink on the homepage shows as http://mywebsite.com But when I open my website I see an absolutely blank page. There is no code in inspect element or no errors in console log. Website can be …
Category: Web

Reverse ordered pagination on home page

Use on the blog reverse pagination. The question arose. How to make a home page is not the first? Need to break the link Home = First page and make a connection Home = Last page. Home should be the last. For example on a blog with 20 pages: Opening the site at httр://www.example.com I get to the home page. And this the same page at the address httр://www.example.com/page/1/ I want to do the opposite: httр://www.example.com opens page 20 (httр://www.example.com …
Category: Web

New WP_Query not isolating custom post types on front-page template

This is the code for my front-page.php template <?php add_filter( 'genesis_markup_site-inner_output', '__return_false' ); add_filter( 'genesis_markup_content_output', '__return_false' ); add_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' ); //* Remove page titles site wide (posts & pages) (requires HTML5 theme support) remove_action( 'genesis_entry_header', 'genesis_do_post_title' ); //* Remove the entry header markup (requires HTML5 theme support) remove_action( 'genesis_entry_header', 'genesis_entry_header_markup_open', 5 ); remove_action( 'genesis_entry_header', 'genesis_entry_header_markup_close', 15 ); // Execute custom home page. If no widgets active, then loop remove_action( 'genesis_before_header', 'vm_utility_bar' ); add_action( 'genesis_meta', 'vm_custom_home_loop' ); function vm_custom_home_loop() { …
Category: Web

Make pagination work as a carousel (custom query)

I'm using a custom query on my static front page in order to show my posts, but I would like my pagination to work kinda like a carousel (instead of loading an entire new url). So, basically I want just the #slides section to load again. Is this even possible? This is my code: <body> [... page content ...] <div id="slides" class="slide bg-mediumgray"> <div id="gridcontainer" class="carousel"> <?php $paged = (get_query_var('page')) ? get_query_var('page') : 1; $counter = 1; //start counter $grids …
Category: Web

How to make transition slider load before home page

I created a transition slider using these instructions on this web site: https://www.greengeeks.com/tutorials/transition-slider-wordpress/ Now I want to take the slider I created and use that as the the first thing seen on my web site before the home page loads on my website. In the slider settings, I enabled the Autoplay delay between transitions settings to 3000ms. How do I do that? Is this something I can set in the dashboard settings for my home page? I would appreciate any …
Category: Web

Wordpress certain directories not connected

Within the main directory ./about the admin bar does not show up and the front page is uneditable(page is being modified but updates do not show) ive come to the conclusion that somehow this is loading a different file external to wordpress. is there a way to stop this from happening and to use wordpress as every other directory works perfectly fine other than those 2 I am also currently using siteground
Category: Web

Categories not posts at the frontpage

can someone please help, i just need a way to display only categories at the frontpage without posts, visitor will enter the website first what he see is the categories , searched all over the web without success thanks
Category: Web

Shortcode not working on static front page

A shortcode from a plugin I am trying to use is not working on my static front page, it only shows as plain shortcode text but It works well on all of my other pages. I'm using Illdy theme, I've already asked about this issue on their forum but I have a feeling that the issue is in my front-page.php file. Is there anything missing or extra in my front-page.php file that is preventing the shortcode from working? UPDATE: in …
Category: Web

Set front_page programatically after user login via query, while leaving site option alone

I want to change the front page based on who is logged in. If User_Bob is logged in, the front page is "Bob" [post id: 123]. If User_Jane is logged in the front page is "Jane"[post ID: 555]. If no user is logged in, the front page is "Main"[post ID:222]. Many other solutions recommend changing options like: update_option( 'page_on_front', $x->ID ); update_option( 'show_on_front', 'page' ); However, this isn't feasible, since I want to do it on every page request with …
Category: Web

Wordpress shows front page, when it should show 404 with pagination style urls

Whenever I type a url for my site that contains three slashes "/" wordpress shows the front page instead of a 404.For example: example.com/something/does/notexist goes to frontpage, where example.com/something/doesnotexist/ correctly shows a 404. I added several debug tools to see what's happening. The rewrite rule explorer shows that no rule matched the request. Yet the front page is loaded. I assume this is related to pagination requests like /something/page/3. What I don't understand is why wordpress does not actually do …
Category: Web

How to set a custom post type post as static front page?

I am writing my custom theme from scratch and I have a custom post type 'my_frontpage' and want to declare one of it's posts as front-page. I want to do this via admin, hence simply add my cpt to the Front Page select box in Appearance >> Customize >> Static Front Page. This issue has been discussed quite a few times in the internet. However, I could not find how to instructions that comprehensively explain all the steps to reach …
Category: Web

Front page is being directed to an unknown site

Unless I type the URL of my site as example.com/wp-login.php, with URL typed as example.com, the front page is automatically directed to the following unknown site: https://elementonfor.live/?utm_campaign=pEv9cTd8QNHYzqqr5UNFx2COHvnp_JE3r8uVIhm3Qww1&t=main9 The above website is unknown, and it is not clear where it has come from. I have scanned my website for malware. The malware plugin I am using shows the website as clean. Not sure what I should do to resolve the issue.
Category: Web

Static page for desktop or mobile

Can you automatically change to a static page if access to the site is via mobile device? Currently my homepage is static and use components that do not work properly with mobile devices but are are necessary for the desktop version. I want to create another static page that will be displayed in the case of mobile devices. I have tried using the code WP Moving but I could not. Thanks for any suggestions.
Category: Web

How to make my homepage automatically redirect to an external website?

Actually, I have a website hosted by my University. They claim that it is my personal website or whatsoever, but they do not give me full control of it! I cannot install plugins, change the theme, or do anything I want because they edited the WordPress panel and removed all of these options. My user is ranked as an administrator of the website. My institution user is listed as a super administrator. Besides that, I do not have FTP access …
Category: Web

What does choosing a Post Page do?

I have always been confused by Wordpress's homepage setting, even though I have read some SO answers and WordPress front page logic cheatsheet. First of all I understand the different between "latest post" and "a static page", so this is not the problem. The problem is with two types of "static page". It seems to me if you have set a page for "Homepage", then the setting of "Post page" is of no use and can be ignored. Is this …
Category: Web

Performing a POST action on homepage goes to posts page

On every page of my site I got a contact form that will send an email to the respective address. On this site also I've set the front page display to a static page. The contact form will basically post to self and if successful will take the user to a new page, otherwise will anchor down to the contact form and display the error. But on the home page, be it any type of POST request, it will set …
Category: Web

Different front page for logged in and logged out user but the same URL in Wordpress

I have two home pages created in WP. One is set as the front page but for only logged-out users. For logged-in users, they see home page 2 as their home page. However, I want the URL for logged-in users to be the default URL of my site. So a mere redirection doesn't work as I will have "site.com/home-2". Is there a way I could achieve this? The code below came across doesn't work and breaks my site. unction switch_homepage() …
Category: Web

About

Geeks Mental is a community that publishes articles and tutorials about Web, Android, Data Science, new techniques and Linux security.