Questions about working with php

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Hamilton Steele
    Registered User
    • Jan 2021
    • 85

    #1

    Questions about working with php

    I'm resurecting an old site of mine and sadly, it needs a good update and facelift. Now despite my education and best efforts, I remain a horrible coder. Let's just say there are good reasons why I always try to use my dick to make money and not my brain. I know that I'm an idiot and I've given up trying to hide it.

    Problem: The original site is in php and it's over 10 years old.

    Questions:

    1. What do I need to download so that I can create a php enviroment on my desktop?

    2. I've been working with Dreamweaver so long that I don't know anything else. Is there something better?

    3. What other questions should a moron like myself be asking about this subject?



    ;
    (Pornstar, Producer, Writer and Pimp)

    http://le-beverley.com/ (Under Construction)
    Email : HamiltonSteele[at]Protonmail.com - Skype - @Hamilton Steele69 / live: cid.afa877d846dcfad5
  • k0nr4d
    Confirmed User
    • Aug 2006
    • 9231

    #2
    Originally posted by Hamilton Steele
    I'm resurecting an old site of mine and sadly, it needs a good update and facelift. Now despite my education and best efforts, I remain a horrible coder. Let's just say there are good reasons why I always try to use my dick to make money and not my brain. I know that I'm an idiot and I've given up trying to hide it.

    Problem: The original site is in php and it's over 10 years old.

    Questions:

    1. What do I need to download so that I can create a php enviroment on my desktop?

    2. I've been working with Dreamweaver so long that I don't know anything else. Is there something better?

    3. What other questions should a moron like myself be asking about this subject?



    ;
    1) XAMP
    2) I use Notepad++, but alot use netbeans, php storm, sublime
    3) Read up on xss, sql injection and csrf.
    Mechanical Bunny Media
    Mechbunny Tube Script | Mechbunny Webcam Aggregator Script | Custom Web Development

    Comment

    • Klen
      • Aug 2006
      • 32235

      #3
      Try this: https://www.apachefriends.org/download.html

      Comment

      • sarettah
        see you later, I'm gone
        • Oct 2002
        • 14297

        #4
        I use WAMP on my desktop

        PSPad as my editor

        And keep a browser open to https://www.php.net/ for reference

        .
        All cookies cleared!

        Comment

        • Paul&John
          Confirmed User
          • Aug 2005
          • 8643

          #5
          WAMP + Notepad++ here as well
          Use coupon 'pauljohn' for a $1 discount at already super cheap NameSilo!
          Anal Webcams | Kinky Trans Cams Live | Hotwife XXX Tube | Get your Proxies here

          Comment

          • redwhiteandblue
            Bollocks
            • Jun 2007
            • 2793

            #6
            You can run Apache and PHP on your desktop although the versions are slightly different to what a server would be running. If the code is really really old there may be some things that are deprecated in newer versions of PHP which might break it but if you run it on PHP 5.6 I don't think you'll find too many. Netbeans is good and free as an IDE, the latest versions need the Java SDK to install.
            Interserver unmanaged AMD Ryzen servers from $73.00

            Comment

            • Hamilton Steele
              Registered User
              • Jan 2021
              • 85

              #7
              Originally posted by redwhiteandblue
              If the code is really really old there may be some things that are deprecated in newer versions of PHP which might break it but if you run it on PHP 5.6
              The code is PHP 3. So it's REALLY OLD


              I studied computer science in university but I have always been a less than mediocre when it comes to any kind of code. Which unfortunately also includes html, php, etc.
              (Pornstar, Producer, Writer and Pimp)

              http://le-beverley.com/ (Under Construction)
              Email : HamiltonSteele[at]Protonmail.com - Skype - @Hamilton Steele69 / live: cid.afa877d846dcfad5

              Comment

              • sarettah
                see you later, I'm gone
                • Oct 2002
                • 14297

                #8
                Originally posted by Hamilton Steele
                The code is PHP 3. So it's REALLY OLD


                I studied computer science in university but I have always been a less than mediocre when it comes to any kind of code. Which unfortunately also includes html, php, etc.
                Install an environment (Xamp, WAMP) make sure to have error_reporting turned on and try to run the code. You will get the errors back, go through and fix, rinse, repeat until you come up with a clean run.

                Once you get past all the syntax and deprecated errors you can get down to making the code actually work again.

                You will learn more about php code by going through the debug than any other method, just my opinion of course.

                Edited in: My answer assumes that you want to learn php coding, of course.

                .
                All cookies cleared!

                Comment

                • Pink24
                  So Fucking Banned
                  • Aug 2019
                  • 1436

                  #9
                  Am I the only one who doesn't like Notepad++

                  I prefer normal Notepad.

                  Comment

                  • sarettah
                    see you later, I'm gone
                    • Oct 2002
                    • 14297

                    #10
                    Originally posted by Pink24
                    Am I the only one who doesn't like Notepad++

                    I prefer normal Notepad.
                    Notepad++ gives you syntax highlighting and lists the functions for a shit ton of different languages.

                    .
                    All cookies cleared!

                    Comment

                    • CurrentlySober
                      Too lazy to wipe my ass
                      • Aug 2002
                      • 38944

                      #11
                      i still use frontpage express...


                      👁️ 👍️ 💩

                      Comment

                      • Colmike9
                        (>^_^)b
                        • Dec 2011
                        • 7230

                        #12
                        Originally posted by sarettah
                        Notepad++ gives you syntax highlighting and lists the functions for a shit ton of different languages.

                        .
                        I need to use that more often, I usually do just black and white. Editors mess me up a lot, when I'm typing in brackets, quotations, etc, that get auto-closed, I end up not paying attention and doubling them.

                        Anyone remember having to run list then stop where you want to look at a section of code, or just printing it all out to debug?
                        Join the BEST cam affiliate program on the internet!
                        I've referred over $1.7mil in spending this past year, you should join in.
                        I make a lot more money in the medical field in a lab now, fuck you guys. Don't ask me to come back, but do join Chaturbate in my sig, it still makes bank without me touching shit for years..

                        Comment

                        • Colmike9
                          (>^_^)b
                          • Dec 2011
                          • 7230

                          #13
                          Originally posted by CurrentlySober
                          i still use frontpage express...
                          Nexus ftw
                          Join the BEST cam affiliate program on the internet!
                          I've referred over $1.7mil in spending this past year, you should join in.
                          I make a lot more money in the medical field in a lab now, fuck you guys. Don't ask me to come back, but do join Chaturbate in my sig, it still makes bank without me touching shit for years..

                          Comment

                          • Pink24
                            So Fucking Banned
                            • Aug 2019
                            • 1436

                            #14
                            Originally posted by sarettah
                            Notepad++ gives you syntax highlighting and lists the functions for a shit ton of different languages.

                            .
                            I don't like the way it stores all old tabs. Like, I can edit an SQL in March and it's still there in September. No idea how to get tid of it. I close the tab and the next time I start the app it's back again.
                            Wouldn't mind but these SQL files are friggin huge.

                            I wouldn't even attempt to open that with normal Notepad though. Think it would shit the bed.

                            Comment

                            • Pink24
                              So Fucking Banned
                              • Aug 2019
                              • 1436

                              #15
                              Originally posted by Colmike7
                              I need to use that more often, I usually do just black and white. Editors mess me up a lot, when I'm typing in brackets, quotations, etc, that get auto-closed, I end up not paying attention and doubling them.

                              Anyone remember having to run list then stop where you want to look at a section of code, or just printing it all out to debug?
                              Yeah, I don't like this either. Tags that auto close themselves. I know it's supposed to help but I end up putting them in twice and wonder why I have a load of errors.

                              Comment

                              • Colmike9
                                (>^_^)b
                                • Dec 2011
                                • 7230

                                #16
                                Originally posted by Pink24
                                I don't like the way it stores all old tabs. Like, I can edit an SQL in March and it's still there in September. No idea how to get tid of it. I close the tab and the next time I start the app it's back again.
                                Wouldn't mind but these SQL files are friggin huge.

                                I wouldn't even attempt to open that with normal Notepad though. Think it would shit the bed.
                                Maybe try turning off remember current session for next launch in Settings > Preferences > Backup?
                                Join the BEST cam affiliate program on the internet!
                                I've referred over $1.7mil in spending this past year, you should join in.
                                I make a lot more money in the medical field in a lab now, fuck you guys. Don't ask me to come back, but do join Chaturbate in my sig, it still makes bank without me touching shit for years..

                                Comment

                                • sexchatvr
                                  Confirmed User
                                  • Jun 2019
                                  • 17

                                  #17
                                  Wamp or Mamp to create local server. If you're connecting to a database you might need to change it from mysql to mysqli, other than that you shouldn't have too much trouble. My editor of choice is sublime but each to their own

                                  Hit me up if you need any help. slowdown [at] gmail
                                  Everything VR - [email protected]

                                  Comment

                                  • sarettah
                                    see you later, I'm gone
                                    • Oct 2002
                                    • 14297

                                    #18
                                    I have no idea on any of that. I do not use Notepad++, I have played with it in the past but I have been using PSPad for at least 10 years so it is my go to.

                                    In PSPad, if you so not close the file before shutting it down, it will attempt to reopen the file when you start back up. But, if you close the file before you shut down, it does not do that.

                                    I would imagine that Notepad++ is pretty similar.

                                    The auto brackets and parens has never bothered me in any way, shape or form. They are right there on the screen. I can see them so I rarely end up typing them.

                                    .
                                    All cookies cleared!

                                    Comment

                                    • Hamilton Steele
                                      Registered User
                                      • Jan 2021
                                      • 85

                                      #19
                                      Originally posted by sarettah
                                      My answer assumes that you want to learn php coding, of course.

                                      .
                                      The only way that I'm going to stop being a moron is to keep learning different things.

                                      I'm working through this but it's going to take me some time.
                                      (Pornstar, Producer, Writer and Pimp)

                                      http://le-beverley.com/ (Under Construction)
                                      Email : HamiltonSteele[at]Protonmail.com - Skype - @Hamilton Steele69 / live: cid.afa877d846dcfad5

                                      Comment

                                      • NatalieK
                                        Natalie K
                                        • Apr 2010
                                        • 20106

                                        #20
                                        Originally posted by Hamilton Steele
                                        The only way that I'm going to stop being a moron is to keep learning different things.

                                        I'm working through this but it's going to take me some time.
                                        not sure why, but your not accepting private messages???

                                        wanting to send you a PM
                                        My official site Custom vids Make money & get into the businessFirst time girls
                                        Skype: GspotProductions - "Converting traffic into income since 2005"

                                        Comment

                                        • Pink24
                                          So Fucking Banned
                                          • Aug 2019
                                          • 1436

                                          #21
                                          Originally posted by Colmike7
                                          Maybe try turning off remember current session for next launch in Settings > Preferences > Backup?
                                          Nice tip

                                          Comment

                                          • Cyber Fucker
                                            Hmm
                                            • Sep 2005
                                            • 12642

                                            #22
                                            Don't be so harsh on yourself.

                                            As for the coding/testing your project locally I find EasyPHP most convenient/easiest, hence the name? (Sadly only for Windows OS)

                                            Mentioned above Notepad++ is good for small edits. For coding in php bigger things/from scratch some php IDE.

                                            Comment

                                            • sarettah
                                              see you later, I'm gone
                                              • Oct 2002
                                              • 14297

                                              #23
                                              Originally posted by NatalieK
                                              not sure why, but your not accepting private messages???

                                              wanting to send you a PM
                                              He just got to 30 posts.

                                              .
                                              All cookies cleared!

                                              Comment

                                              • NatalieK
                                                Natalie K
                                                • Apr 2010
                                                • 20106

                                                #24
                                                Originally posted by sarettah
                                                He just got to 30 posts.

                                                .
                                                how many posts do you need to make before you can accept messages?
                                                My official site Custom vids Make money & get into the businessFirst time girls
                                                Skype: GspotProductions - "Converting traffic into income since 2005"

                                                Comment

                                                • Pink24
                                                  So Fucking Banned
                                                  • Aug 2019
                                                  • 1436

                                                  #25
                                                  Originally posted by NatalieK
                                                  how many posts do you need to make before you can accept messages?
                                                  30 posts.

                                                  Comment

                                                  • NatalieK
                                                    Natalie K
                                                    • Apr 2010
                                                    • 20106

                                                    #26
                                                    Originally posted by Pink24
                                                    30 posts.
                                                    so how come still unable to send messages, and 31?

                                                    says, and I quote..

                                                    Hamilton Steele has chosen not to receive private messages or may not be allowed to receive private messages. Therefore you may not send your message to him/her.
                                                    My official site Custom vids Make money & get into the businessFirst time girls
                                                    Skype: GspotProductions - "Converting traffic into income since 2005"

                                                    Comment

                                                    • Applebite Media
                                                      Confirmed User
                                                      • Apr 2018
                                                      • 406

                                                      #27
                                                      Apache NETBEANS!!! Best damn program for coding out there and it's FREE!!!

                                                      See sig if you want help. I'm slow at the moment and can help if you need it. ;)
                                                      ================================================== ============================

                                                      Help, HELP!.... Jane, Stop This Crazy Thing!!!!!!

                                                      Stop renting software!
                                                      Say NO to Rentware!

                                                      Take a Bite - Applebite Media

                                                      Comment

                                                      • Hamilton Steele
                                                        Registered User
                                                        • Jan 2021
                                                        • 85

                                                        #28
                                                        Originally posted by sarettah
                                                        He just got to 30 posts.

                                                        .
                                                        I'm hoping to get back the original account I registered in 2003. So, I've been talking via email with one of the mods and I'll see how it goes. If I get it back, I'll have to start over againl


                                                        Originally posted by NatalieK
                                                        so how come still unable to send messages, and 31?

                                                        says, and I quote..
                                                        Bizarre but I'll take a look at my user cp

                                                        FYI: I've been talking to one of the admins and I'm hoping that they'll give me the account that I registered in 2003. If that happens then I'll once again need to post 30Xs in order to get private messages.
                                                        (Pornstar, Producer, Writer and Pimp)

                                                        http://le-beverley.com/ (Under Construction)
                                                        Email : HamiltonSteele[at]Protonmail.com - Skype - @Hamilton Steele69 / live: cid.afa877d846dcfad5

                                                        Comment

                                                        • S3X_Jay
                                                          Registered User
                                                          • Dec 2020
                                                          • 38

                                                          #29
                                                          I use PhpStorm. It's a pretty good IDE.

                                                          You don't really need a to run PHP locally. Just create a dev area on your server and run it there. When you save a file in PhpStorm it can automatically upload it, so no need to jump through any complicated processes. And by running it on the server it will be the same exact environment as when you deploy it publicly, so no surprises down the road.
                                                          For the past 12+ years I've focused on building & running gay affiliate sites.

                                                          Comment

                                                          • k0nr4d
                                                            Confirmed User
                                                            • Aug 2006
                                                            • 9231

                                                            #30
                                                            Originally posted by S3X_Jay
                                                            I use PhpStorm. It's a pretty good IDE.
                                                            It's nice, but it doesn't do anything to justify a 200eur/year license cost
                                                            Mechanical Bunny Media
                                                            Mechbunny Tube Script | Mechbunny Webcam Aggregator Script | Custom Web Development

                                                            Comment

                                                            • Applebite Media
                                                              Confirmed User
                                                              • Apr 2018
                                                              • 406

                                                              #31
                                                              Originally posted by k0nr4d
                                                              It's nice, but it doesn't do anything to justify a 200eur/year license cost


                                                              Agreed

                                                              I tried the demo.... It was ok but lacking.
                                                              ================================================== ============================

                                                              Help, HELP!.... Jane, Stop This Crazy Thing!!!!!!

                                                              Stop renting software!
                                                              Say NO to Rentware!

                                                              Take a Bite - Applebite Media

                                                              Comment

                                                              • S3X_Jay
                                                                Registered User
                                                                • Dec 2020
                                                                • 38

                                                                #32
                                                                Originally posted by k0nr4d
                                                                It's nice, but it doesn't do anything to justify a 200eur/year license cost
                                                                Click on "For Individual Use" and you'll see you can get it for a lot less than 200. Most people in porn don't work for big corporations, so individual use is probably the appropriate license.

                                                                And also notice the amount you pay goes down every year.
                                                                For the past 12+ years I've focused on building & running gay affiliate sites.

                                                                Comment

                                                                • NickBaer
                                                                  Nick Baer
                                                                  • Jun 2005
                                                                  • 1393

                                                                  #33
                                                                  I use Komodo for actual php editing, but since 2015 I have liked Bootstrap pages...

                                                                  So I find a Bootstrap site package that looks interesting, then copy/paste the design elements into my Komodo .php page. And I use my MojoHost SQL, as well as Google Sheets as data sources.

                                                                  Like https://Coach-Karl.com or https://the-British-Beef.com or https://gay-dvds-for-women-and-men.com/

                                                                  My sites are catalog pages, not member sites, and feature my self-built shopping cart, based on a plan from CCBill. CCBill is my payment processor. https://Porno-Mall.com is actually about 200 lines of .php, reading a massive Google Sheet.

                                                                  Yesterday, I found a "Heat Map" sample page in js. (For sales statistics for a Cam site I broadcast on.) I used Komodo to make a .php script to read data from my Google Sheet, then output the .txt file in the format that the HeatMap script needs. Which BTW, is .html and .js! Not that I really needed to do this, as I only have a couple of hours a day to broadcast during, but it is practice for something bigger in the future. Such would look more interesting for a model who is on longer hours, or on multiple shifts per day.

                                                                  Made my first porno in 1986. Sold my first VHS in 1993. Did my first live Cam in 1994. Coach-Karl.com NickBaerGallery.com I host with MojoHost.com and To Buy or Sell Sites Imagine AI Content

                                                                  Comment

                                                                  • k0nr4d
                                                                    Confirmed User
                                                                    • Aug 2006
                                                                    • 9231

                                                                    #34
                                                                    Originally posted by S3X_Jay
                                                                    Click on "For Individual Use" and you'll see you can get it for a lot less than 200. Most people in porn don't work for big corporations, so individual use is probably the appropriate license.

                                                                    And also notice the amount you pay goes down every year.
                                                                    Yeah, In my case though I'm a software company so it's not individual use, and honestly if I had to blow like 2k euros per year on a text editor for all my staff when it doesn't really do much more then netbeans...

                                                                    Edit: I just installed phpstorm demo version. At a quick glance not much here that netbeans doesn't have. I'll stick with notepad++
                                                                    Mechanical Bunny Media
                                                                    Mechbunny Tube Script | Mechbunny Webcam Aggregator Script | Custom Web Development

                                                                    Comment

                                                                    • NickBaer
                                                                      Nick Baer
                                                                      • Jun 2005
                                                                      • 1393

                                                                      #35
                                                                      Since 2005, I have written many hundreds of .php scripts, some with Bootstrap, .js, and more like Google Maps, using Komodo.

                                                                      I edit my page, upload the file to my MojoHost account (either via FTP or the Komodo built-in FTP save option), and refresh my Chrome page.

                                                                      I never use a desktop environment, as what matters is the php runtime on MojoHost - with local files, SQL or Google Sheets data sources.
                                                                      Made my first porno in 1986. Sold my first VHS in 1993. Did my first live Cam in 1994. Coach-Karl.com NickBaerGallery.com I host with MojoHost.com and To Buy or Sell Sites Imagine AI Content

                                                                      Comment

                                                                      • NickBaer
                                                                        Nick Baer
                                                                        • Jun 2005
                                                                        • 1393

                                                                        #36
                                                                        php.net is the source reference.

                                                                        You can use StackOverflow as a reference. Use a fresh Google page to search on your php question. It will generally find a half-dozen StackOverflow threads.

                                                                        Usually better to not pose a direct question on SO, but rather to use Google to search for previous threads. It will also find references on W3Schools, and other industry specific forums.

                                                                        Reading SO threads can be a bit tedious. The OP states the question, then others jump in with wrong answers and misinformation - like here. So you do need to read all the way to the bottom, then by trial and error, find what works best for your instance.
                                                                        Made my first porno in 1986. Sold my first VHS in 1993. Did my first live Cam in 1994. Coach-Karl.com NickBaerGallery.com I host with MojoHost.com and To Buy or Sell Sites Imagine AI Content

                                                                        Comment

                                                                        Working...