Support » Fixing WordPress » upload landing page to wp

  • Hi all
    hope someone can help me with this.
    I have been trying to get/ copy/upload a landing page to my site.
    This s from anstrex.
    I can send to my host bluehost, root folder public-html and the page is live but then there is no capability to edit the page.
    I really need to have this page in my pages list in wordpress.
    I have tried everything.
    send to media . gives error cannot upload security file type not allowed.
    upload to new page same problem
    Upload to new page with elementor.
    upload to saved templates etc.
    all methods give the same error.
    I have tried to rectify this error by adding code to php file to allow upload of all file types but some files still show an error.
    I have used 2 x plugins to configure the file upload types allowed but these did not work.
    Tried to upload page directly to my pages in database and can upload but still the page does not show in my wp dashboard pages.
    Used filezilla and file manager and ftp etc.
    This is driving me crazy.I have spent days trying to do this.
    Anyone know how i can achieve this .
    Would greatly appreciate any help.
    Thanks,
    Tony.

    • This topic was modified 11 hours, 10 minutes ago by Jan Dembowski. Reason: Moved to Fixing WordPress, this is not an Everything else WordPress topic
Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi Tony.

    I’ve not come across Anstrex before, so you may have to help me understand what exactly you’d like to add to WordPress. If it’s a landing page, and you’ve been given a public-html folder, I’m guessing you have a .html file and maybe some additional files (.css, images) along with it?

    Do you know if the landing page is optimised to work with your WordPress theme (Elementor)? If it’s not, I’d recommend uploading the files directly to your host like you already mentioned. Otherwise, you may see unwanted side-effects within your theme, such as conflicting stylesheets and markup. You can still link to your landing page from within WordPress using the path from your hosting.

    In order to add this page to your page list in WordPress, the best way to achieve this would be to create a custom page template. You can then create a new page from your WordPress admin, and use your new template instead of the default one. You will then need to add your custom landing page markup to the .php file for your new template.

    First, create a new page within WordPress as you normally would. There’s no need to fill in the content, just give it a title for now and publish it.

    Then, create a template for this specific page as explained here: https://developer.wordpress.org/themes/template-files-section/page-template-files/#creating-a-custom-page-template-for-one-specific-page

    To create a template for one specific page, copy your existing page.php file and rename it with your page’s slug or ID:

    page-{slug}.php
    page-{ID}.php

    For example: Your About page has a slug of ‘about’ and an ID of 6. If your active theme’s folder has a file named page-about.php or page-6.php, then WordPress will automatically find and use that file to render the About page.

    From here, you should copy and paste your landing page markup into your new template file. You could replace the content that is inserted from WordPress with your landing page content. Alternatively, you could add it just before or directly after the WordPress content. For example, replace The Loop with the markup from your landing page:

    <?php while ( have_posts() ) : the_post(); ... ?>

    You’ll need to update any references to images or other files with their respective locations from either your media library or where you have uploaded them via FTP, e.g. for any .css files or image files. If there are .css files, these may conflict with the styles in your theme.

    The above is also assuming that the landing page will work within your existing header and footer markup from your theme.

    By adding content directly to a template like this, you won’t be able to edit it from within WordPress. This is possible but would involve a more advanced template set up and you’d essentially need to recreate the landing page you’ve been given. If you’re not comfortable with doing this yourself, it would be worth asking Anstrex if they can provide a landing page that works with WordPress or your theme (or anything similar they can provide to help with this, e.g. a plugin or a different theme.)

    Hope this helps or gives you some ideas that you may not have tried. Let me know how you get on.

    Just thought of something else if you go down the route of creating a custom page template for your theme!

    The best way to make changes like this is to use a child theme, and then your changes won’t be overwritten when updating the theme.

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.