The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

2 Pages V < 1 2  
Reply to this topicStart new topic
> How to hide a part of a screen?
Stefan197203
post Mar 4 2020, 10:49 AM
Post #21


Newbie
*

Group: Members
Posts: 14
Joined: 1-March 20
Member No.: 27,214



The screenshot seems from my own site. You have access, so I wonder where you implemented the solution.
- When I click the link, it still shows the button : https://aqqii.com/w2/?trp-edit-translation=true Did you remove the solution?
- The button is just below your screenshot, so I can't see the result.
Where did you incorporate the code?

Thousand thanks!!
Stefan
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Mar 4 2020, 11:04 AM
Post #22


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,716
Joined: 9-August 06
Member No.: 6



I just viewed source, saved it locally and added my CSS snip.

Look at the scroll bar. I've scrolled the page to the bottom. There's nothing below.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Christian J
post Mar 4 2020, 03:23 PM
Post #23


.
********

Group: WDG Moderators
Posts: 9,628
Joined: 10-August 06
Member No.: 7



QUOTE(pandy @ Mar 4 2020, 05:04 PM) *

I just viewed source, saved it locally and added my CSS snip.

Did you include any javascript? Maybe they change the HTML somehow.

User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Mar 4 2020, 04:10 PM
Post #24


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,716
Joined: 9-August 06
Member No.: 6



I didn't change anything more than that I added a style block and slapped on a base href. The page looked the same as online before I added the CSS snip. Almost everything is CSS. So without JS there wouldn't be much to look at.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Mar 4 2020, 04:17 PM
Post #25


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,716
Joined: 9-August 06
Member No.: 6



QUOTE(Stefan197203 @ Mar 4 2020, 04:49 PM) *

The screenshot seems from my own site. You have access, so I wonder where you implemented the solution.
- When I click the link, it still shows the button : https://aqqii.com/w2/?trp-edit-translation=true Did you remove the solution?
- The button is just below your screenshot, so I can't see the result.
Where did you incorporate the code?

Thousand thanks!!
Stefan


Ah! I get it. You thought I had changed your page? No, I don't want to mess with your stuff on the server. You need to add the CSS yourself. biggrin.gif
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Stefan197203
post Mar 5 2020, 05:30 AM
Post #26


Newbie
*

Group: Members
Posts: 14
Joined: 1-March 20
Member No.: 27,214



Great! One last bit, before the solution works. How to activate this CSS to the page (as the page is delivered by the plugin, so we can't add it, without the code being removed with every update of the plugin).
E.g. in header.php or functions.php something like:
If this page (https://aqqii.com/w2/?trp-edit-translation=true) then run this CSS
Thanks thanks thanks!
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Mar 5 2020, 06:03 AM
Post #27


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,716
Joined: 9-August 06
Member No.: 6



The WHOLE page? Isn't the plugin embedded in a page, even if it's pretty much empty before the JS does it thing?

If you have a page and the link to the plugin JS is in the page, all you need is to put the CSS either in a style block in head or in a external linked style sheet.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Stefan197203
post Mar 5 2020, 10:45 AM
Post #28


Newbie
*

Group: Members
Posts: 14
Joined: 1-March 20
Member No.: 27,214



Plugins are installed on WordPress, not on a page.
So the page is not defined in the WordPress installation, but the whole page comes from the plugin.
Therefor it's impossible to add CSS to the page, as normal.
I can however modify header.php, functions.php and so on. They are not overwritten by a plugin-update, nor by a WordPress update.
Any resolution? Thanks for taking it this far!!
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Mar 5 2020, 10:46 PM
Post #29


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,716
Joined: 9-August 06
Member No.: 6



Well, then I'm out of ideas. I don't know if it's possible to manipulate a page with something serverside without actually touching the page. Christian?
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Mar 6 2020, 12:14 AM
Post #30


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,716
Joined: 9-August 06
Member No.: 6



But... It's impossible for them to create a page on your server from their server, that simply can't be done, so I took a look at what that TranslatePress really is. You have uploaded a bunch of files on your server. One (or several) of them must contain the skeleton for the page we see. I think I found it.

Take a look at translate-manager.php in the folder partials.

At line 65 or thereabout you have this.
CODE


    }
    ?>

    <title>TranslatePress</title>
</head>
<body>

    <div id="trp-editor-container">
        <trp-editor
            ref='trp_editor'
            trp_settings='<?php echo ...



From <title> and a few lines forward there's plain HTML, no PHP. Try putting the style block just after TITLE. Just be careful not to change anything before the PHP closing tag (?>) above TITLE or after the next PHP block starts. Make a backup of translate-manager.php first, so you can easily replace the file on the server if things after all screw up.

CODE

    }
    ?>

    <title>TranslatePress</title>

    <style type="text/css">
    #trp-upsell-section > p    { display: none }
    </style>

</head>
<body>


Fingers crossed! tongue.gif
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Christian J
post Mar 6 2020, 07:17 AM
Post #31


.
********

Group: WDG Moderators
Posts: 9,628
Joined: 10-August 06
Member No.: 7



QUOTE(Stefan197203 @ Mar 5 2020, 04:45 PM) *

I can however modify header.php, functions.php and so on.

I suppose you could let header.php create the HTML for linking or embedding a stylesheet.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Christian J
post Mar 6 2020, 07:20 AM
Post #32


.
********

Group: WDG Moderators
Posts: 9,628
Joined: 10-August 06
Member No.: 7



QUOTE(pandy @ Mar 6 2020, 04:46 AM) *

I don't know if it's possible to manipulate a page with something serverside without actually touching the page. Christian?

A PHP script can include files from another server, but I don't know if Wordpress' PHP scripts actually do that.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Mar 6 2020, 09:00 AM
Post #33


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,716
Joined: 9-August 06
Member No.: 6



No, I meant if you can manipulate a specific page on the same server without embedding PHP in the same page.

Like if instead of loading the TranslatePress thing directly when a link is clicked, the link leads to a script that does something to the TP document before it's loaded and then sends it to the browser.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Christian J
post Mar 6 2020, 05:46 PM
Post #34


.
********

Group: WDG Moderators
Posts: 9,628
Joined: 10-August 06
Member No.: 7



I have no idea what you mean. unsure.gif
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Mar 9 2020, 07:50 AM
Post #35


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,716
Joined: 9-August 06
Member No.: 6



OK.

Stefan197203, have you tried to edit translate-manager.php yet? I'm curious.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Stefan197203
post Apr 15 2020, 07:43 AM
Post #36


Newbie
*

Group: Members
Posts: 14
Joined: 1-March 20
Member No.: 27,214



QUOTE(pandy @ Mar 9 2020, 07:50 AM) *

OK.

Stefan197203, have you tried to edit translate-manager.php yet? I'm curious.


Hi Pandy, sorry I was some time unavailable but now found your suggestion and implemented it. It worked smooth, the button is removed!
Thanks a million, you are excellent!!
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Apr 17 2020, 03:40 PM
Post #37


🌟Computer says no🌟
********

Group: WDG Moderators
Posts: 20,716
Joined: 9-August 06
Member No.: 6



Good to know. smile.gif
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

2 Pages V < 1 2
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 19th March 2024 - 03:06 AM