News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Installation of ssl certificate

Started by webbuilder, November 05, 2012, 11:55:41 AM

Previous topic - Next topic

webbuilder

I want to put a ssl certificate such that it appears on every page....in the white space just above the forum to the right...ie. just above the "notify", "mark read" buttons........

I know a little html, no php really and no javascript really....and I basically don't quite know where in the SMF this should go....

I have the javascript code snippit and need to paste it somewhere....

can anyone save me some time and point me in the right direction.....thank you, you guys are a help 

webbuilder

maybe another way to ask this question....if I want to put a piece of javacript say for an ad into Simple Machines Forum...much like where the online manual is at the top of this page.......where does that go in the code?

MrPhil

I guess the first question is, "do you really have an SSL private certificate installed, and if so, how are you using it with SMF?" Most people will tell you that it's not terribly useful for SMF, although it can be done. I'm a bit worried that you're confusing terms. Assuming that you actually do have SSL such that you can access your forum under https:, what is even the point of declaring on each page that you have SSL, when the browser will clearly tell everyone? I'm just trying to avoid wasting a lot of yours and my time trying to stick some Javascript in the template somewhere.

To answer your specific question, I'd have to look through the code (in the default theme) for where those buttons are defined, and figure out a good place just before that to stick in some code. Actually, if all it is a graphic announcing that you have SSL, why is Javascript involved? It's not just a snippet of HTML? Let's make sure everything is straight on what you're trying to do, and then we can take a look at where to put it in the default theme. From there you're on your own if you're using some other theme.

And of course, round up the usual suspects: what SMF version and what mods are installed? When I zero in on a particular part of a file, you will be responsible for modifying my instructions if any of your mods have changed that area.

webbuilder

Hello, thank you for the reply.....to answer your questions....

I'm using the default curve theme, version 2.02.......I have a few mods installed but nothing that should affect this.....I just can't find a location (likely somewhere in index.template.php) in the code that will work and I don't want to wing it too much...sooner or later I'll break the thing.....

Yes, I do have a valid ssl certificate....this is a little banner that opens up a little certificate.....it just looks nice....or would if I could get it where I want it.......and to your point, I may be mixing my terms.....sorry.......last time I did any significant coding was some html with a wysiwyg editor about 5 years ago.....so my html is a little shaky......it's coming back though.....

but, here is the little piece of code with the actual address substituted with HHHH

<span id="siteseal"><script type="text/javascript" src="https HHHHHHHHHHHH"></script></span>

thank you for your help....

MrPhil

Quote from: webbuilder on November 05, 2012, 06:13:08 PM
I do have a valid ssl certificate....this is a little banner that opens up a little certificate.....it just looks nice....or would if I could get it where I want it.......

<span id="siteseal"><script type="text/javascript" src="https HHHHHHHHHHHH"></script></span>

Um, SSL is more than a pretty certificate. You have purchased a dedicated IP address and purchased a private SSL certificate (installed by your host), such that you are able to run your site under https: ? I just want to get that confirmed before spending any time on this. If I may ask, what is the objective in using SSL with SMF? As SMF is written, either the entire thing is under SSL, or nothing is. The only thing you will gain from SSL is that a hacker can't eavesdrop on traffic between your members and your site. You would have to carefully set permissions so that only members can see anything, else there's no point in protecting access to what unregistered guests can see anyway. It will do nothing to protect you from being hacked. It will slow down your system quite noticeably. You will probably have to edit SMF code to fix it up so it uses https: instead of http: when creating certain links for items embedded in a page.

Your responses so far have not given me comfort that you understand this. Are you in fact to the stage where you can successfully access your forum under SSL (https: )? If so, we can discuss where to put that line of code to display the certificate.

webbuilder

I don't see that you're following.....all I'm looking to know is if someone can advise where to place a snippet of code....it doesn't seem like it's an unusual request...after all it could be an ad I want to put there.....that's all I'm asking, not to get into all the efficacy of this or that.....

But since you mention it, yes, I know SSL is more than a "pretty certificate", the idea is to have a secure connection on logins...we'll see on the speed.....it's not to limit who sees what content......anyway, as I said, I thought that someone with some experience might simply point to where a piece of code might go...if that's not the case or you don't want to bother with it....skip it.....

anyone else?     

Colin

Have you already purchased and enabled the SSL? I can see Phil's concern. We are worried that this might be deceiving users of security when in fact you aren't using SSL.
"If everybody is thinking alike, then somebody is not thinking." - Gen. George S. Patton Jr.

Colin

webbuilder

The hosting company is presently setting up the SSL, there's a lag time of 24 hours while they do that. They gave me the little piece of code to put on the site meanwhile......

The site is under construction with no users logging in and no financial transactions being done besides...so there is no need to worry ......is there?

So back to my original question...is this really an unusual question that a user new to SMF might want to know where to put a piece of code so something appears in a certain area ...as I said I want to put some ads in that vicinity too.....I mean this is the coding section, right.....I guess I'm not seeing that this should be a difficult question........am I wrong in that? I mean I';ve gotten it to appear already in places I don't want it...and I've only worked with SMF for about 5 days....so I thought.....maybe ..someone would know......





 

webbuilder

For any newbie, here's my solution, some expert will probably tell me this is not how to do it....

Used the Ad Content Mod
http://custom.simplemachines.org/mods/index.php?mod=255

Pasted the code snippet in to the box, and checked "Display ads on message index".....then used a little html to right align it....the &nbsp; puts a space after it...that dropped it right into the spot I wanted it......one can also check options to have it on every page......

this is the html that right aligns it.....


<div style="text-align:right;">

Code Snippet here

&nbsp;
</div>

I prefer to put the code in myself...but, what I'm discovering with SMF is that there seems to be a Mod that can either be used to do something or used in conjunction with a little simple html......so to get it done.....

That's just my take on it


MrPhil

Quote from: webbuilder on November 05, 2012, 08:28:35 PM
The hosting company is presently setting up the SSL, there's a lag time of 24 hours while they do that. They gave me the little piece of code to put on the site meanwhile......

The site is under construction with no users logging in and no financial transactions being done

OK, that's what we wanted to hear. Although I'm still not sure what you are planning to have SSL do for you, at least on the SMF part of your site, it sounds like a proper installation is being done. It sounds like you found a way to place the SSL logo or seal in your SMF, so you're good to go. Let us know if you run into trouble with that part.

Advertisement: