Wordpress Cusutom Page, With PHP,js html and css

How can I implement a full html,php,js and css page into a wordpress page? Example: I have a app.php that has a text box, when You press enter it displays the text with a php echo. With the users profile picture from Facebook.

How Can I inset/implement that into a WordPress page?

Answers


HTML/PHP: The simplest way may just be to create an extra template in your theme. You can view WordPress template hierarchy here: Template Hierarchy

JS/CSS: If the JavaScript and CSS makes the most sense to be embedded (it usually does!), you can use hooks and actions in a simple plugin (or potentially your functions.php page) to include the JavaScript and CSS you need.

Note: I have not personally used functions.php (found in your theme files) to call these sorts of hooks, but I assume it would work just fine.

If you are using a theme that constantly receives updates, it is worth building a plugin to do the job. If not, it's easiest to just modify the theme.


There are two options as far as I know. First one is that you embed the code directly into your posts, and install the plugin called PHP execution. Second, try to create your own page template, and place your own code in the template. then you can create a page in the dashboard and select the template.


Need Your Help

Writing and reading long strings

c++ database string file-io

I am writing a program to act similarly to a database. It takes a job number, first name, last name, job description and job duration.