Currently developing a theme for Wordpress site which needs to have two versions of every page. The case is that the pages should differ whether browsing as one type of customer(b2b) or another(b2c). This should be controlled by a url variable.
An example of what i am trying to achieve.
www.domain.com?version=b2b - b2b frontpage
www.domain.com?version=b2c - b2c frontpage
www.domain.com - Fallback b2b frontpage
In the admin area the best solution would be having those two different frontpages connected like when using WPML or other multilingual plugins (even though i am not searching for a language plugin).
I have tried to google this case with no luck and all i cand find is the language plugins.
Looking forward for your help. I am really stuck :)
Related
I want to make my site multilingual. So, now I want to make sug for all pages like my-domain.com/ar, my-domain.com/bn, and more. I want my all pages slug changed by language but load page content same as I'm using google translate and it's working well but I want to work with google translate by chaining URL slug by language.
It is possible or do you have any suggestions, please?
Thanks
i'm trying to set up an archive page using wordpress (with elementor) that lists 3 other articles (all blog posts but could be normal static pages). the archive page is to have basic info of its own then summary versions of the 3 articles below it, each with "read more" links that link to the full page versions (the usual thing). this is the intention anyway. elementor says i need pro version to do this, astra theme also seems to want this. i haven't been using wordpress very long & am not yet familiar with the php templating side of it am trying to avoid it if possible as i just want to hurry up & finish this site. but if i must i'll get into the php.
anyway, any assistance would be helpful. even if it's just clarifying what i'm not understanding at the moment. cheers in advance for any help
After developing hundreds of websites with Astra and Elementor, I can confirm your suspicion. And even if you do have the PRO version of Elementor, you are still incredibly limited in designing the "Archive Layout" as elementor only supports 1 block for the "post listings".
TL;DR: Elementor Anywhere will let you create highly reusable templates/themes to circumvent PRO features, and add much more granular customization of elements in "The Loop".
yesterday i stumbled across Sergey Burkov's wordpress plugin 3DPrint Lite and I'd like to use it for my website. I'm currently using dokuwiki and don't want to switch to wordpress only for this single purpose. There aren't any similar solutions to Burkov's plugin and coding it all by myself is no option.
.I'm asking myself if its possible to only use wordpress' backend or something similar. So that I would end up with only one page. (Login and so on has to stay available of course)
Any suggestions?
You don't need to switch to wordpress for your whole site, just to use that plugin. Not hard to install wordpress in a directory on your site, and then if you don't want to use any wordpress pages, just use the login from yoursite.com/directory/wp-admin.
If you don't want yoursite.com/directory to show at all then you could do a redirect of that url only, perhaps to your homepage.
Just don't try installing wordpress at yoursite.com since that will mess with your current site.
I’ve been experiencing a problem that I was hoping someone could point me in the right direction. In an effort to make my website more mobile friendly, I purchased a mobile responsive theme. While I know I could have created a sub-domain or a directory to house the mobile version of the website, I’ve been attempting to have the original domain http://example.com switch themes based on the user. In other words, for http://example.com, Desktop user views DesktopTheme and Mobile user views MobileTheme. With the Any Mobile Theme Switcher plugin, I was able to accomplish this will little issue. However, for certain pages I would like to be able to display the desktop version to the mobile user. For example, for single posts, I would like the desktop user and the mobile user both to see the DesktopTheme.
Unfortunately, after several hours of searching and experimenting I am not further along than when I started. Using different templates appeared to be an option, but it’s not a true theme switch. When I altered the template files, mobile users received a hybrid version of the site that includes the mobile header and an unstructured version of the desktop version. A similar result was achieved when I simply copied the single.php file from DesktopTheme into the folder for MobileTheme.
Example:
<?php get_header('/var/www/html/wp-content/themes/DesktopTheme/header.php'); ?>
Any ideas?
There is a plugin that you can use for switching themes based on the post type as well as a lot of other conditions:
http://codecanyon.net/item/wordpress-theme-switcher/558740
I'm not aware of any free version that offers the same functionality, but that doesn't mean one doesn't exist.
With that said, I think you should reconsider your approach here. The entire point of responsive design is so you do not have to have separate mobile and desktop sites. I think you should sidestep this entire issue by using the responsive theme everywhere.
Using a single responsive theme is going to make maintenance much easier and give the user a more consistent experience.
Also, get_header is meant to load a header file from the current theme. You can't load components from other themes and expect them to work correctly.
I have a question regarding how best to build a widget/plug-in for WordPress.
I have tried to code this thing out but unfortunately to no avail but that's because I'm increasingly thinking I'm going about it the entirely wrong way.
This is what I'm trying to achieve:
I have built a theme from scratch. In this theme I have two content areas. The larger of the two contains the main content and the smaller of the two (proposed widget/plug-in) contains supplementary information (opening times, Facebook feed). I don't want this widget/plug-in to appear on every page and would like the ability to turn it on or off within the usual WordPress admin area.
The impression I am getting is that I can build the widget that contains the content I want (with necessary forms to change said content) but it is either on for ALL pages or off for ALL pages, no sort-of page specific functionality. That's where I'm thinking a plug-in would extend the functionality and allow me to be more page specific with it. That is my current set-up with a theme I'm running and plug-in I added (neither of which were coded by me) but I would like to repeat it as best as possible.
Would it be right to assume that widgets are not really designed to have page specific functionality and that function should be left down to a plug-in?
I appreciate this question asks nothing really in the way specific advice but I would just like an opinion or two on the best approach before I go away and create it - this is my main struggle at the moment.
Thanks for looking.
This can be done with the Jetpack plugin. Once activated you can choose what widgets display on what pages:
The Widget Visibility module enables you to configure widgets to appear only on certain pages (or be hidden on certain pages) by using the Visibility panel.
Visibility is controlled by five aspects: page type, category, tag, date, and author. For example, if you wanted the Archives widget to only appear on category archives and error pages, choose “Show” from the first dropdown and then add two rules: “Page is 404 Error Page” and “Category is All Category Pages.”
Originally posted here
It is also possible with the Display Widgets plugin.
This is a common problem. The usual remedy is to use an existing plugin that allows widgets to be tied to pages.
The 3 most popular plugins for this are:
JetPack
Per Page Widgets
Widget Logic