Jump to content

PeterBubresko

Members
  • Posts

    22
  • Joined

  • Last visited

Everything posted by PeterBubresko

  1. Thanks to both of you. I am so new to this so got to admit I don't know what is or what, or what is the best way to do this or other things, but I am learning. So for now I move the file(s) outside of the www dir, and later when my experience has grown, I will use Moorcams solution. I Choose to do it this way because I don't need more scripting to remember now. So, for a later time when I have other things under control, I keep in mind Moorcams solution.
  2. Thank you Maxxd. Could this be done without moving the includes directory outside the www directory by only changing the permissions on the includes directory while inside the www? directory?
  3. Quote from a book: Instead of repeating this code at the top of every file, we can move it to an include file. Include files are just like normal PHP files, but typically they contain snippets of code that are only useful within the context of a larger scripts. As such, as with templates, we don't want people to be able to navigate directly to these files by typing the filename into their browser, as they only Structured PHP Programming 224 contain small snippets that won't produce any meaningful output on their own. We'll solve this problem the same way we did with templates: by creating a directory outside the public directory, so that any files are placed in this new one directory can only be accessed by other PHP scripts. We'll call this directory includes, and use it to store our code snippets. Inside the new includes directory, create a file called DatabaseConnection.php and place the database connection code inside it: Quote end. Does this mean that I/you create an area outside the www directory on the server, or is the new "includes" directory placed in the root of www directory?
  4. Thank you both very much. These answers were very well explained. I Will come back to these topics. It was a lot to digest at once.
  5. I am trying to read me up on PHP again, and now I am trying to understand what a framework is, and what a controller is, and what a controller does. Okay, first thing first. I have understood or misunderstood that a framework is a platform or an application developers are using to program or set up a site or a script like VS Code or Dream Weaver etc. If I read about a framework on another website a framework is like a template. Can someone please tell me what it is. There is also this with controls. Is this a script that will operate in several places or be called on several times? To save time, this is put into a separate file that is called on from different places multiple times. What is the right thing here, and am I completely out of my mind? I am confused about this.
  6. First thing first: What do the three letters, GIT, mean in GitHub? What is a GIT? Apart from that, the word "mode" was used in a lack of a better word. Thank you for all your well-explained answers. Since I'm a small-scale "hobby programmer", I'll give GitHub a chance, but it will probably mostly be in private "mode". Docker has a utility value equal to zero in my eyes. So, I may have more questions about GitHub coming up.
  7. Thank you requinix. I understand that Docker is complicated, and I don't see that it's something I absolutely need, at least not yet. But the questions still arise. As I understand you, and what I have read about Docker online, Docker is "a place" where you find PHP, MySQL etc. as a kind of pre-installed "something" so that you don't have to burden your computer with heavy tasks and in some cases to save space. When it comes to saving storage space, I guess GitHub is a more suitable place/service, because as I understood you, it's something that can be compared to a "repository", because that's what it is, right? I don't know if I'm on shaky ground now, but in my small-scale hobby programming projects, it's just as well for me to install MySQL and PHP locally on my computer and let "my old trotter" struggle a little more, it's despite all not the heaviest tasks I feed my computer with. As for GitHub, this seems more applicable and more relevant to me. A question that quickly arose, and which I think I have heard talked about or read online. Does GitHub work in two different modes? Is it designed so that in public mode the code is open to everyone so that they can go in and correct the code or comment on the code? By correcting the code, I mean that you can give help and get help from others who can read the code on GitHub. Maybe I was completely wrong now? Eagerly waiting for a reply.
  8. I am trying to familiarize myself with, install and configure Visual Studio Code, but this seems like you have to be a skilled programmer just to set up VS Code. Among other things, there is a file called Json, or something similar. This file that needs to be configured. Have no idea what this is, or what to do with that file. Here you have to enter commands and paths that I have no idea what they are, or how they should look/point to etc. I will primarily use VS Code for PHP, MySQL and Python, and eventually for JavaScript. Is there anyone in here who can help me with the installation and configuration? During the installation, I get to a step where I have to choose from several boxes, but I can't find anything about debugging PHP or MYSQL, which I will primarily use VS Code for, and what is this Docker and GitHub? Do I need it, and for what? I'm still new when it comes to programming, so I need input at the feeding me kindly T-Spoon level. Can someone please help me understand this?
  9. This was more clearifying. Thank you for the answer.
  10. I couldn't find a separate forum topic for XHTML, so I'm posting here on HTML. I "think" I have over time allowed myself to be tricked into believing, and therefore misunderstood, where and when I should use <HEADER></HEADER> in XHTML. As before and always, there are as many answers as there are questions on the internet. I have been using this error for a long time. I thought it should only be used between <head> and </head> So in one last attempt, I hope to get more unanimous answers here that lead me out of the vicious circle. Now and where is it correct to use <HEADER> and </HEADER> in XHTML? Should those tags be used on one or more elements arbitrarily between the <body> tags, and in which places/tags should they be used.
  11. I Didn't understand anything. Too many choices to choose between behind the link. I find it out by myself. I know what to look for now. Thanks any way
  12. I am in the process of putting together a system where I include a MySQL database. In this I have table user which contains username in the form of an email address, and the password. The page includes a good deal of user information, therefore passwords and usernames are separated to only be in the users table. The other user information I need, but which is kept away from the users table, is the user_inf table. Is it possible to somehow connect these two tables together? so that I can still retrieve the user information where I want/need? This has something to do with the fact that I need the user's e-mail address elsewhere together with the information in the user_inf table, yes also..... argh, forget it. Is there a solution so that my users do not need to register their e-mail address in two places in the registration form in order to save it in two different tables? Primary key is ID .
  13. Ok guys. Thanks for the Information. I am new to this and learning while i'm living. I will try to correct it/me so i get it right.
  14. I am trying to center a picture for my site logo. Can you see whats wrong? <div class="logo"><img src="images/logo/logo.png" alt="Logo"/></div> img.logo { align: center; height: 139px; width: 950px; }
  15. Okay, I understand gizmola. Not much has happened since last time. Lots of trouble in Norway again the last weeks due to the coronavirus and the new one, omikron. Now Norway is mostly closed down again from today. Now it so happens that before I read your recommendations, I had already created an account at 100 webspace. Therefore, I will use them for now, but have your recommendations and tips in mind. I will see if I can do a little now tonight before I go to work and broadcasting tomorrow early morning (yawn.) I will post the first thing I do as soon as I understand more of this 100 webspace thing.
  16. Thanks Gizmola. You realy cleared it up for me when it comes to Semantic and HTML5. Is that the same as XHTML. I have started to learn HTML4 or something. But when i was reading what you wrote i can see that there is a lot of adventage in HTML5 instead of HTML4. Maybe stupid question. Is HTML5 the same as XHTML? I am not so confused anymore. Just alittle. But i am learning. I get a jint here and a hint there. Another thing is i was looking for was a place to save my home page and had help from a person on a forum to a norwegian news paper. He told me about this ( www.100webspace.com ) in USA. Its a free service. I thought i had to pay a lot of money for a domain and a space where i could save my home page. I just have to find out how to save it on internet and i can show you what i have made. Sugestions would be fine when i ask for it. First i will try to find it out my self.
  17. I can see that. To me it seems like it is 100 different ways to do things. For me it seems like developers is not so concerned with the standards that they should be. They know about them, but they do not use them to often. take a little from there and put it in another place. I read a bit about browsers, and have realized that if you make a mistake in a script, it is not so important. Think it was called green browsers. As I understand it, a browser today is capable of correcting errors itself. Possibly I am wrong and that I will make more mistakes. I'm fresh and new to the subject and that's why I ask all these (for you) stupid questions. At least I now understand that there is no shortcut to creating a website. So I feel a bit stupid asked the question the first time I came here on phpfreaks.com Actually, I do not understand much of what I am trying to learn, but I catch up a little here and there. So what you tell me means a lot. Og det er det jeg har gjort. Tatt litt her og puttet inn der. Er det så galt. Jeg får et da til å vises noe på skjermen. And is it so importent with that validator thing? It is confusing me more than i learn of it. Because when i try it out in that validator it tells me that it not standard and has a lot of errors. But when i open the site in my browser it is perfect. Thats why i dont understand this standard thing. Can you explain this a little for me. I dont think I realy understand... or what you mean? Iwas reading a litle on the box model site. But more i read, more questions i got. I hope it is temporary. I can't do more this night. I am finished in the makeup now and It's broadcasting from 07:00- 10:00. Good Morning Norway. ...or....what is this XHTML thing? Another standard of HTML or the same?
  18. First i get a good advice that was working. Then i get another advice because the first one wasn't good enough. I am just trying to learn something new here. The first og them works pefectly the way i want it to be. So why confuse me me with one more? Any way, i got to ask. What is the right way, and what is the best way? As long they are working and do theire job for me i dont realy see the problem or care. I just wanted the first words of a line to be bold. Gismola: Thank you so much for the link. I was looking at it, and that is just what i need. On the page you sent me to i found so much more. I need more of those kind of sites, please? Thank you.
  19. I have written several lines of text. Each new section should begin with bold and highlighted text. This is controlled with CSS (ext. file). I have tried to create a class for both <p> and <h1>. Both close with </ **> It's not that they do NOT work, nope, they make the text both highlighted and bold, but the text that comes after </ **> comes on a new line. Why? What am I doing wrong? p.head_line { font-family: "Helvetica, Ariel"; font-weight: bold; font-size: 14px; font-color: # 000000; } h1.head_line { font-family: "Helvetica, Ariel"; font-weight: bold; font-size: 14px; font-color: # 000000; } <p class = "head_line"> Bold Text </p> Normal text................. <h1 class = "head_line"> Bold Text </h1> Normal Text.............. The normal text begins on a new line but should continue on the same line after the bold. How do I do it?
  20. There were many words and expressions I do not understand. Think this needs to be studied. I have read a bit in the books, but do not understand anything. Maybe you can help me understand the expressions and sentences you come up with? What does framework mean, and what is it used for? What is it to write a security code? What is the difference between programming and coding? Can I create a good website with just one of html, xhtml, css and php? And what are javascript and jqerry. It probably says more about this in my books what you two above say to me. It is also easier for me if you to write it here so I can copy the text directly into google translate. It is a lot of work for me to write the text in the books into word and copy it from there and paste it into google translate. You answer me and I understand what you are writing to me so it is possible to communicate in this way.
  21. I'm new here and need help. I'm new to everything in here. Is there a shortcut to learning programming. I have just become unemployed from the fish reception where I worked and have plenty of time to spare. I was therefore in the store today and bought myself two books to make myself a website. I will make this to search for a new job. This one says about xhtml 5 and css which is supposedly one language for creating websites. This book also said about the programming language php, but it only says that it can be used. Nothing about how to do it, it does not say anything about what it is. That's how I came across this forum. I'm trying to figure out what I've been up to. What is the difference between coding and programming? Are there any programs that can help me create a website? Can anyone tell me what I do? What should I do to learn this? It seems complicated. The books I bought are in English and are called HTML 5 and css 3 all in one for dummies and beginning html 5 and CSS 3 for dummies. She who works in the store said these were good books I wanted to learn from because there are lots of examples on the internet and on CD rooms. Do not understand anything of what I do yet. Can anyone explain this to me in a simple English way? My English is not very good. Therefore, I have to use google translate to write English. Hope for your understanding of this.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.