I have a site where i need to control the content by external site like, Wordpress or Joomla or drupal. HOw can i do it? Any suggestions are very much appreciated. If i edit it here, changes needs to be reflected in my external site..
I think, you should link the database of your CMS set up (e.g. your WordPress site) with your external site. Whenever you will do edit there, the changes will be reflected on the external site. But, first of all you should have written code in the external site to fetch data from your CMS database.
Obviously, just after linking to the CMS database, the required data will not be fetched and shown on your site. You will have to refer tables structure of the database and accordingly write queries and present it on your external site in the way you want.
Also, for instance your CMS is WordPress and external site is coded in PHP,
You'll need to use core PHP functions and DB queries as WordPress API functions won't work on your external site.
Related
I am new to web development and and would like advice about what is the usual best practices to achieve what I am trying to do.
I am in charge of writing a frontend app using Vue. This frontend will require a login to access the app. The app will be hosted on Amazon.
However we are also wanting to build an eCommerce site in Wordpress or equivalent that sits on the root of the website, (eg www.mywebsite.com) with the app accessible through a "sign in" button. If the user presses the sign in button we want the location bar location to not change from the website they are on (www.mywebsite.com), even though the Wordpress site and Vue frontend may be stored on different locations/domains.
If the site is made in Wordpress, we can get another developer to do that webpage for us, while I work on the frontend. However we want the experience to be relatively seamless between connecting to the wordpress root site, clicking on the sign in button and being taken to the Vue frontend.
Is this possible? Do both sites have to be hosted on the same server for it to work (eg an Amazon EC2 server which hosts two webpages, the wordpress one and the vue one)?
Or can the wordpress put a link to the Vue frontend which doesn't change the web location to the user?
Or (worst case scenario) do we need to make both webpages in Vue as one Vue application, some pages requiring login to access and others not?
Thanks kindly for any assistance.
So in order to use Vue and WordPress together, you can either write 2 separate applications. One for the Frontend and one for the Backend, which is perfectly fine or you can simply write a WordPress Application with a Vue Theme.
This is how this could look like:
WordPress Backend
You can use a normal WordPress backend, where you can build the architecture you want to. In addition, you need to set up the REST-API Wordpress provides. So this also means, just use plugins which support it. Otherwise, you would need to write custom endpoints. For example, Woocommerce would be a good e-commerce plugin, since it supports the API.
Learn more about it here: https://v2.wp-api.org/
Of course, you can host your WordPress installation on Amazon. Here is a good guide for that: https://aws.amazon.com/de/getting-started/tutorials/launch-a-wordpress-website/
Notice: The REST-API is available in core since 4.7. If you are using an older version you would need to install a plugin.
WordPress Frontend
In order to create your Frontend, I'd recommend you to make a custom theme. Since you are just serving static files this can be done pretty easy. But still, you don't need to reinvent the wheel.
There's a really good starter theme out there: https://github.com/EvanAgee/vuejs-wordpress-theme-starter
It comes with all the stuff you need to get started and since it is just a theme, you can simply set up a usual WordPress hosting without handling Domains of multiple applications.
In order to get the data from the Backend, you would simply make calls to the REST-API. Here's an example: https://github.com/EvanAgee/vuejs-wordpress-theme-starter/blob/master/src/api/index.js
I would like to build Single Page Web Application (SPA) with React.js.
Application would need some Content Management System for back-end. I was thinking to use WordPress and their REST-API's but I don't know how to retrieve data from my wordpress installation.
Back-end and front-end would be in different domains so just building WP theme with React.js wouldn't work.
Basically, I don't know how to call and populate data from wordpress to my front-end.
I would need someone to point me to the right direction. And, maybe recommend easier CMS to use in this task.
Actually it is very easy to access your WordPress website data through HTTP REST API
Here you have the full documentation on WordPress REST APi
http://v2.wp-api.org/
Would like to integrate Cakephp project with Wordpress. Any ideas how to do it best?
It should be my created information system which several pages could be launched from the Wordpress website.
Would like to have everything under one domain - Wordpress website blog (for describing the system) and the system itself.
At the moment I have my information system and bought a Wordpress theme also. Need Wordpress functionality to enrich my current information system based on CakePHP.
The need is to use Wordpress as the login, description, documentation mechanism. That's why I'm not sure how to do it under one domain the best way. Just need consulatancy how to make these two systems with their own databases to work together withinn one domain name.
If more specific - one of the Wordpress page should be the login page of my information system which is handled by the CakePHP MVC. Is that possible?
Maybe it could be done similarly to this approach:
http://www.eiosys.com/blog/solved-install-run-integrate-wordpress-blog-alogside-with-cakephp/
Or maybe here is almost what I need:
http://www.abhinavsood.com/install-cakephp-in-subdirectory-of-wordpress/
Any better ideas?
I intend to use WP to setup a freelancers website (similar to oDesk) to connect service providers with service seekers in a WEB 2.0 dynamic environment. This site requires multiple forms to enter and retrieve information using database and show them in filtered or non-filtered views in separate pages.
Please advise if there are available plugins to expedite developing this site, or otherwise any guidance would be appreciated. I specifically would like to know how to connect forms to database and then how to retrieve this information from the DB.
Regards,
You are likely going to have to create your own custom WordPress theme, using various custom PHP pages to connect your web forms to your database. I think your project is well beyond the scope of a simple WP plugin.
If this was my project, I'd ditch WordPress and go for something custom built in Rails. WordPress is a good enough CMS, but it isn't really a good fit for what you are looking to accomplish.
I want to build a web site in wordpress. A web version like mysite.com and a mobile version like m.mysite.com. I am thinking that will it do able in wordpress because wordpress save domain name in database.
mysite.com/m will be possible but the requirement is to go with m.mysite.com.
The approach in this helped me: http://www.phillipadsmith.com/2011/11/note-to-self-a-simple-way-to-accomplish-mobile-site-redirection-using-mod-rewrite.html
However, proper creation of templates and css will really make the need redundant.