Wordpress Plugin with database for Networks Sites - wordpress

Ok, So i know how to code a Wordpress widget plugin. But what i want is to create a plugin to display some external links(Like Title and Link) in Footer of websites(Networks Sites). These links are different on each Network site.
So can anyone tell me how can i store those links in database for each Network sites ?
Thanks in advance

Go to the footer widget, and activate Custom Links, make sure you use the full HTTP address.

Related

How do I integrate a website template on my main wordpress website?

I have a Wordpress website made to show a portfolio of websites, so the client can have an idea about what kind of wordpress-based website I can create for them.
My question is, is there any smart way of creating a live website template inside a website? My approach would be to install another wordpress release into a folder (e.g domain.com/template1; /template2 etc.) but it feels kind of...ancient.
Is there any other way or am I steering into the right direction?
I would say, the easiest way is to make a second customize.php, because there you have the possibility to take a live preview and make a new site template with it.
Important: Do not forget to restrict a lot of settings like, choose this Template - otherwise it will be set as default for your website :)

Is there a way to create custom URLs in WordPress for each client

I'm trying to create a site for a client who want's to use the WP Workscout theme. He want's a client portal that's able to do 2 things;
The clients logo and basic chosen style in their portal area
A url for the client for example clientname.companyname.com
I could do this quite simply with a custom site but I'm not sure about WordPress. Is it possible? If so, how?
Any help would be greatly appreciated
You might want to consider building a WordPress multisite. Sounds like it might be what you're looking for.
It will allow you to have some different styling for each site in the network, and you can set up each site on different subdomains.
https://wordpress.org/support/article/create-a-network/
https://www.wpbeginner.com/wp-tutorials/how-to-install-and-setup-wordpress-multisite-network/

Headless CMS: Wordpress Rest-API – Add links to existing posts/pages

We want to use the Wordpress Rest-API to build a page decoupled from the backend. A few things still bother us though:
Within the wordpress backend one can add links in the content editor of a page or a post and one gets normally a list of all existing pages and posts of the same page to link to them. By decoupling the backend it does not know the exact urls to other pages and we need to provide this. Is there a possibility to tell wordpress what links are available?
Thanks in advance.
Cheers
For those looking for the answer:
There are two URL settings under Settings > General.
WordPress Address (URL) should be the URL for your api site. Like api.whatever.com.
Site Address (URL) should be the URL for the frontend. Like www.whatever.com.
This allows the internal linking to work properly in the Editor while keeping the backend site on a separate URL from a headless frontend.
I'm not sure what you're trying to ask. The WordPress REST API just provides a way to access posts, etc. from somewhere else part from the web site side (e.g. themes, etc). Pages would still be accessible from the admin backend and the JSON/REST API: https://developer.wordpress.org/rest-api/reference/pages/
Specifically with WordPress you could ensure that you're not rewriting the permalinks. That way they are all still site.com/?p=post-id
That way it's easy to parse fetch the new pages. Then replace the hrefs with whatever your frontend needs.
You could use the ID to fetch the slug of the new post immediately.
Or you could even keep a mapping in your presentation layer of IDs to your own slugs.
Changing the site_url doesn't work for me.
Since I also have a wordpress theme with custom rest controllers
Plus the wp-json breaks if I change the site url
My backend is hosted at digital ocean app
My frontend is hosted at vercel
I fixed it by using a wordpress plugin called make-paths-relative
But since my backend doesnt know where my frontend is I added one change within the plugin at:
frontend/class-make-paths-relative.php line 123
I added a constant FRONTEND_URL which i define in the wp-config
$relative_link = FRONTEND_URL.$link;
This changes both the permalink within my backend of a post, page or cpt
And changes internal links as wel, links within the content editor
I made a request to the plugin author as well

Wordpress themes in cpanel

I am here to ask a question regarding WordPress themes in c panel.
i installed WordPress in c panel and its working fine but I want to make the operation like, just by clicking on a theme name it should display the WordPress theme without going to admin panel i.e i am giving demo in my website about the themes which i have in my server.
it like www.something.com/templates by entering in this link i should get the list of templates for themes and by clicking on it i should get the demo of that theme.
Note : i installed wordpress in 'templates' folder in my Cpanel.
Hope I find solution for this.
Thanks in advance
I suggest you use plugin like demo theme provider so use this WordPress plugin : https://wordpress.org/plugins/ijm-theme-bar/
These can help.!
https://wordpress.org/plugins/wp-demo-builder/
WP Demo Builder is the most powerful and simplest way to let your
potential customers truly experience your WordPress products. A game
changer and the first of its kind, our service helps you create
separate demo sites that allow your users to literally do everything
with it, both backend and frontend.
https://wordpress.org/plugins/demo-bar/
This plugin helps to add demo bar for displaying your different theme
demos.

Adding Wordpress Blog to Existing Website: Is Database Required

I have been asked to add a Wordpress blog to an existing website and wanted to ask the group a few tech questions.
The website is static, does not run with a database in the background, was created with plain html/css and is hosted on a generic server.
If I were to add a blog to this site, would I need to set up a database to hold the content?
If no database is needed, could content be uploaded/removed using ftp software one would normally use to manage a website like this?
Could the original Wordpress navigation and css be replaced with the css and navigation for the website?
Could the blog support widgets like as 'like' or 'add this' without the use of a database?
If anyone has insights they can share I would really appreciate it.
Thanks,
Peter
If you want to install WordPress, you will need a database. Check the codex for the full list of requirements for installing WP.
Other than this, yes, you can mimic the navigation and design of the main website by creating a custom theme.

Resources