Code bbcode in phpbb3 - bbcode

Here is a question for the code bbcode in phpbb3. As we can see here (official site of phpbb3) two ways of presenting a code are used. Is this a bbcode? If so, how can I add it to the board? If not, is this a mod? If yes, where can I find it?
I have searched a lot of how I can achieve a result like this but I came up empty. I appreciate for your help.
Edit: I am talking of course about the code that is presented as an inline next to the text.

I'm not sure how phpBB implement it, but you could use BBcode to achieve the same effect. To add custom BBcode go to the Posting tab in your ACP, and BBcodes is the first option in the left column.
BBcode usage:
[inline-code]{TEXT}[/inline-code]
HTML replacement:
<span style="background: #fff none repeat scroll 0 0;border: 1px solid #c9d2d8;color: #2e8b57;display: inline;font-family: Monaco,"Andale Mono","Courier New",Courier,monospace;font-size: 0.9em;font-style: normal;line-height: 1.3em;padding: 0 3px;">{TEXT}</span>
Help line:
[inline-code]Your code here[/inline-code]
The above css is taken from the link you posted so should look the same on your site.

Related

Bottom of the page footer positioning issue

I'm having a hard time figuring out how to make my footer stick to the bottom of the screen, even when the page is smaller than the screen.
www.test-domain.sk
I'm guessing it's something to do with the container length, but I'm honestly completely unsure.
Any help would be appreciated. :)
This concept is something known as a sticky footer. The Mozilla Developer Network has a page here illustrating a few ways to accomplish it. In the example of your www.test-domain.sk page, I believe you can add the following css to make your footer stick to the bottom of the viewport (screen).
html {min-height:100%)
body {100vh}
div#page {min-height:100vh; display:grid; grid-template-rows: auto 1fr auto}
Assuming you are looking for something like this, but if not, be more specific. As in post the code you already have.
footer {
position: fixed;
bottom: 0;
}

How to locate the element as per the HTML through FindElementByXPath in Selenium Basic

I'm writing a VBA code to login into a webpage and load some information i have in an excel worksheet.
I'm new in Selenium. I already got the login part right, but now i need to click in an element and i keep getting errors.
I need to click in the Company 2 button.
This is what i've got so far:
bot.FindElementByXPath("//input[#value=""Company 1""]").Click
Outputs NoSuchElementError
bot.FindElementByXPath("//input[#value=""Company 2""]").Click
Outputs ElementNotVisible
I don't know what i'm doing wrong, i think that the first input being hidden has something to do. Hope anyone can help me.
Might help you to know you can also use ByCss in most circumstances, in which case you can use:
bot.FindElementByCss("input[value='Company 1']").Click
That is nice and short.
The CSS selector is input[value='Company 1']. This says find element with input tag having attribute value with value of 'Company 1'.
XPath might be incorrect. Please try the following syntax:
FindElementByXPath("//input[#value='Company 1']")
First of all, use CSS selectors whenever possible. They are much easier to handle.
Now if you are using CSS selectors try to find the second button using something like
input[value="Company 2"]
For more info on this selector, look at https://www.w3schools.com/cssref/sel_attribute_value.asp
You can use any xpath, in first look I found your xpath is incorrect, try this:
//input[#type='button'][#value='Company 2']
//input[#type='button'&& #value='Company 2']
//input[#role='button'][#value='Company 2']
You can also use findelements() to store are all buttons and using if else you can extract the company 2 button
As per the HTML you have shared to invoke click() on the desired elements you can use the following solution:
To click on the element with text as Company 1:
bot.FindElementByXPath("//input[#class='btn_empresa ui-button ui-widget ui-state-default ui-corner-all' and #value='Company 1']").Click
To click on the element with text as Company 2:
bot.FindElementByXPath("//input[#class='btn_empresa ui-button ui-widget ui-state-default ui-corner-all' and #value='Company 2']").Click
Have you tried right-clicking the HTML in inspect and going to Copy>Copy XPath? That might give you something different. Maybe the buttons are created from Javascript and so the WebDriver can't actually see them?
Or try
Company_1 = bot.find_element_by_xpath("//input[#value='Company 1']")
Company_1.click()
Company_2 = bot.find_element_by_xpath("//input[#value='Company 2']")
Company_2.click()
And change the syntax with the ' ' quotes like someone else mentioned.

Dreamweaver Template '##'

I've been researching the use of templates and repeating sections with Dreamweaver and I was reading the Adobe page on repeating sections (http://help.adobe.com/en_US/dreamweaver/cs/using/WScbb6b82af5544594822510a94ae8d65-7ab0a.html).
At the bottom of the page there is an example of using a repeating section with a table and making the row background colours alternate using
<tr bgcolor="##( _index & 1 ? '#FFFFFF' : '#CCCCCC' )##">
Curious about this '##' tag, I started Googling 'dreamweaver double at' and similar things but failed to find anything. It appears to be some sort of script, however I can't find any further information about it. If anyone could point me in the correct direction that would be most appreciated.
Those are template expression. Look here Template expressions

Can't click "through" fixed div menu

I'm having problems with my fixed menu. As you can see of the example beneath it's not possible to click the links "VingÄrde, Dyrkning..." because of the div box with the fixed menu on top of it. I've tried ordering the layers with z-index but I just can't get it to work. Can anybody help me out?
http://itu.dk/people/mbul/humlum/
And if anyone by the way have a method on auto adjusting the height of the page so it covers the whole viewport I would be very glad to hear from you :-) In the website version above I've set the height manually to 1000px which is not preferable
Thank you!
You need to put all the wrappers' elements outside of it and put them after the left-page container and before the right-page container. Finally, remove the wrapper, it seems unnecessary for the page in order to work.
I fixed it through Chrome's dev tools, but I assume it should work if you modify the html that way.
The body should look like this:
<div id="left_page_container">...</div>
<div class="nav_humlunvim">...</div>
<div class="nav_butik">...</div>
<div class="nav_blog">...</div>
<div class="nav_kontakt">...</div>
<div id="right_page_container">...</div>
Hope it helps; as an extra observation it is more common to use "hyphen-separated-names" for selectors than to use "snake_case_names" :)

Onload page make div slide visible with easing

I'd like to have a div (with class="top") come slide in from top:-300px; to top:40px; with some nice easing. I can't find any examples. Does anyone knows how to do this on load page?
Here's some JavaScript and CSS3:
The JavaScript:
<script>
document.getElementById("slide").style.top="40px";
</script>
And the CSS:
-webkit-transition:all 1s;-ms-transition:all 1s;-moz-transition:all 1s;-o-transition:all 1s;-webkit-transition:all 1s;
The element that would slide would have to have the id "slide". It would also need top have "position:absolute;top:-300px" in the CSS to make it -300px. You could also add "left:20%;" or something of the sort to the CSS to make it look better. Whatever works with your design.
You should look up about the CSS transition property. It's very nice for special effects. In this case, I made it take 1 second to slide. You could always change it.
This could also be implemented using jQuery, a JavaScript library, (which would take even less code), but I usually prefer regular JavaScript and CSS if I can help it.
Here's a demo of the code I wrote above: jsFiddle.
Oh, and PLEASE mark this question as the answer if it helped you. It will give me privileges and earn me more reputation.
Hope this helped!

Resources