Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Server Side

This forum is dedicated to Server-Side development including: PHP, Node.js, Ruby, Go, Databases etc.

  1. Started by webdeveloper93,

    So I got this idea from the threads general JavaScript and General CSS so this is General PHP. Feel free to post PHP snippets that others may find helpful. I will start... Remove From Array By Value Simply removes a given element from an array by its value <?php function removeFromArrayByValue($array,$valToRemove) { if(!is_array($array)) { return; } $newArray = array_diff($array,array($valToRemove)); return $newArray; } Usage <?php $arrayMinusVal = removeFromArrayByValue(array("red","green","blue","orange"),"blue"); //Will output red,green,orange... blue is removed foreach($arrayMinusVal as $newVals): echo $newVals."<br />"; endforeach;

  2. So i see this posted over and over again by users wondering how to fix the PHP warning Warning: Cannot modify header information headers already sent . So I am going to list the known causes of this warning and any other member feel free to add onto the list if i missed anything. Known Causes/How to fix Having HTML output/Php echos before calling header('Location:page.html');(Call the redirect before any output or turn on output buffering) Having white space before calling session_start() can result in headers already sent warning(Remove any white space before calling session_start also note session_start must be called before any output at the top of a pag…

    • 9 replies
    • 8.3k views
  3. Started by teodora,

    Here's the node thread, however I have an idea. Seems like all of us are at different stages with node.js, some are beginners (me! ), some have better understanding and possibly have built apps and what not. What we could do is to start consecutive threads, starting from the beginning (installation, etc.) and gradually going into the deep end. What are your thoughts?

  4. Started by Sam G,

    The most commonly asked question on the Server Side (PHP, Databases, ASP.NET, etc) forum is "how do I create a contact form?". Well... The answer to that question depends on what you want - do you want a ready made form that you can use on your website, or do you want to learn how to code your own form? I have listed below several links to help you on your way. All links/tutorials/script generators are free. DIY (Do-It-Yourself) Contact Form Tutorials Free, simple, PHP based email contact form PHP Contact Form with jQuery Validation Writing Your First PHP Script: Feedback Form Script Ready Made Scripts A Nice & Simple Contact Fo…

    • 0 replies
    • 17.9k views
  5. Started by Sam G,

    Handy Links for Web Designers & Developers The following are links that I have come across over the years, and links submitted by other forum members. All of the products, services or tutorials featured on these websites are FREE! Note: This list is by no means exhaustive, and will be updated periodically. Accessibility Validation Accessibility Color Wheel HiSoftware Cynthia Says Luminosity Colour Contrast Ratio Analyser WebAim WAVE (Web Accessibility Evaluation Tool) FTP Clients And Servers Cyberduck FTP Client (Mac OS X) FileZilla FTP Client (Linux, Mac OS X, Windows) FileZilla FTP Server (Windows) PureFTPd FTP S…

    • 0 replies
    • 14k views
  6. I have a domain and it was setup for me as an alias on another cPanel account. I only ever used it for a single email address. I think aliases no longer exist in cPanel and it is just listed as a domain. I wish to move it to its own cPanel account so it can have its own cPanel settings eg website, SQL etc. This would all be on the same virtual server (ie the same IP address) in the same WHM It looks like I do this by creating a new cPanel account with the domain in WHM and then removing the domain from the original cPanel. I imagine I would lose any emails saved on the server etc but as long as I use the same login credentials in the new cPanel then the email would contin…

  7. Started by chtyrone,

    I have decided to convert my old online mdb website to accdb. Hopefully this is just a meeter of changing the asp Currently looks like this: Anybody got any ideas on where I can a tutorial to help write the new 'link' code?

  8. I've been working almost exclusively in Wordpress lately and I'm not sure how to migrate a non-Wordpress site. Would ftp access be the best way to move ospreypointtn.com, or do I need to check with the developer to see if there's any databases associated with it? Thank you for any feedback.

  9. Started by Monie,

    Hi, anybody here knows the simplest Classic ASP function to truncate a long text? Example: 1. This is a very long text. 2. This is a very... Text got truncated at certail length.

  10. Started by doublejz,

    So I'm having an issue incorporating recaptcha into an existing site. If I try to add the recaptch script as well as form submit validation it stops procssessing the PHP from the submit on. Now if I rewrite the form to not be PHP I lose all my formation CSS styles. Below are what I'm referring to. No captcha <form action="index.php" id="contact-form" method="post"> <ol class="forms"> <li> <label for="name">Name:</label> <?php if($nameError != '') { ?> <span class="error"><?=$nameError;?></span> …

  11. Started by Monie,

    Greetings, I have successfully implemented this script (PHP Directory Lister) into my workplace document management system. What I plan to do now is to add in a simple audit trail or audit log of user activity on that system: What file user download (time and date). Document their IP addess Login date and time Does any of you ever did this or can anybody share some idea where to go from here? Thanks.

    • 7 replies
    • 2.8k views
  12. Started by PPMark,

    Dear gurus. I have a virtual server with a number of domains. For PCI compliance I need on one of them to switch off the 3306 port. In another I need to change the port. On the others I want to leave them as is (open on 3306 but only allowed from given IP). I believe this is done in config files located in the etc folder for each domain and can be done in cPanel. My question is, are all these mysql ports independent per domain? My worry is there one instance of mysql on my virtual server, and if I change the port on one domain it’ll change it for all and mess them all up.

  13. I have a text area that contains text. After a button is clicked, this text is put into a div with spans for each word for styling purposes. For example, the text could say "Hello World!" This will be split into 3 spans, one for each word and one for the space in between the words. Now, if a user selects part of the text in the text area I need to detect which spans contain the string that has been selected. So the user could select from the 'o' from 'Hello' up to the 'o' from 'World'. In this example, spans 1, 2 and 3 have been selected. How can I detect this? You'd think this would be simple but I'm struggling to find a way to do it. Here are some variables I've set up:…

  14. Simply speaking, I'm working on a JavasScript website that allows users to enter text into a text area. After clicking a button, the text area text is displayed on a separate part of the screen. But it isn't displaying the way I want it displayed. The best way to describe the issue is to give an example, so here's an example. This is the text the way it is meant to look: USING THE FIRST LETTER OF YOUR NAME TELL ME SOMETHING THAT MAKES YOU HAPPY! In the above example, the user has added line breaks at the end of each line. But this is how it is displaying after the button is clicked: USING THE FIRST LETTER OF YOUR NAME …

  15. I’m a UX designer who has to do some web development on a vendor’s platform. The vendor’s system is php and frequently uses iframes to place content, so I spend a lot of time trying to find ‘creative’ solutions to pages I have to build myself. I’m creating a basic css tab menu. I need to be able to link users to this page with specific tabs open for different use cases. Our vendor says they can’t help us with this “because it’s a php page”. I feel like this should be possible, but I don’t have deep dev knowledge. Stripped down example: https://studiotoolkit.dmplocal.com/sites/4054/tabsforhelp.html I appreciate any suggestions. Thank you!

  16. Hi all. I'm having a issue with rewriting a rule for my ht access where I have have a simple slug work for my website I'm building Here is my url for a dynamic page I have: dev.mysite.com/views/blog/page.php?page_slug=post-one I'm trying to get it so I can add the URL in the address bar so this would work: dev.mysite.com/blog/post-one Here is the current .htaccess RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^ index.php [QSA,L] Any heklp most apprciated.

  17. Hi. I am new to Web Design/Web Development and would like your guidance. I have a keen interest in car modifications. I would like to create a website which would allow users to upload photos/videos of their car modifications and to add a description with the upload. I would like other users to be able to comment on the modifications and up/down vote each modification in order to create a ranking/a favourite by the month/year. With each comment added it should grow the site's activity levels. I understand I will need to learn HTML/CSS/JavaScript as front-end languages. The Jon Duckett books are highly rated but some are quite old. HTML and CSS - published 2011.…

  18. Hi, I want to create a web app where the user uploads a photo and downloads it after applying the desired filter to the photo. Do I have to use the database? Is it necessary to store the photo in the database? regards, Saeed

  19. hello friends, I was following a youtube video on making a s tudent management system with codeigniter3 but i am stuck at some point when i click on edit on view students page..its showing me the details of same student whatever student i choose here is the code for view viewStudents.php <?php include('inc/header.php');?> <div class="container mt-2"> <h2>Students</h2> <hr> <?php echo anchor('admin/dashboard','BACK',['class'=>'btn btn-warning']);?> <div class="table-responsive"> <table class="table table-hover"> <thead> <tr> <th…

    • 0 replies
    • 1.9k views
  20. I've been wanting to get more confident with web development for a while now, and am gradually getting more comfortable with frontend (HTML, CSS, JS). I'd like to learn more about backend, but honestly it's kind of intimidating how many options there are out there. What I'm looking for some guidance on is: how can I pick a web stack/framework, while minimising the amount of new things I would need to learn all at the same time in order to get a working solution quickly? (I'll clarify below what I know already) E.g. if you told me I needed to learn the MEAN stack I would say "That's going to be very difficult, as I've never used MongoDB, Express, Angular or NodeJS, so…

  21. This page isn’t working myweb.in is currently unable to handle this request. HTTP ERROR 500 how to fix it

  22. Mình đang cần người thiết kế một trang web giống như https://cameraaigon24h.com về camera ngành. Ai làm được thì inbox trực tiếp cho mình để được giá cả.

    • 1 reply
    • 2.1k views
  23. Any libraries or examples of cascading select menus where the options are dependant on the selection of more than one other seelction menu in a group? There are lost of examples of of one menu depndant on the selection of a single other but I'm looking for something more advanced where the options are dependandt on the slection of two or more of other select menus in a group? Thanks in advance

    • 1 reply
    • 2k views
  24. Started by crystal-clear,

    Hi guys i'm new to the forum! I was wondering what it would take to build a "number plate search" into a website... So when the user types in their vehicle number plate the website can work out what make/model the car is and therefore offer a service suitable for that car. Kind regards, Mike.

    • 15 replies
    • 23.1k views
  25. Started by JohnCity,

    I have noticed that if I put a cookie acceptance bar on for example www.example.com it comes up with no issues. However if I put it on for example www.example.com/news/ it does not show. Obviously Im not that experienced and have only just got round to thinking I need to sort this out. Reason is that I have a top level where the cookie bar shows, under this are several websites for charities. So in theory a viewer can go directly to a particular charity page, thus bypassing the main index page. Appreciate some guidance on this.

    • 4 replies
    • 2.1k views
  26. Started by BWD Group,

    Good evening, we have been given access to a 3rd Party API on behalf of a client to request live data from their systems using JSON. Where can I find good resources on how to request values and output them in a response ? most of the tutorials online are covering JSON files and how they work which is great but the actual server connections and response seems to be a little vague or really in-depth. We have used cURL with JSON before but this API looks a little more advanced and requires POST variables that are nested so how would you access them with a POST query. Any help would be great. Thanks

  27. Started by eugenemdonaghy,

    Hello adding a contact form to my website www.eugenemdonaghy.co.uk/contact.php having a fatal error regarding a undefined function the donor page has the same error http://www.eugenemdonaghy.co.uk/CSS3_six_dark/contact.php what should be done to correct this my php knowledge is non existent

  28. Started by RobertS,

    I'm researching security headers and made some notes, and wanted to confirm I have it down right. Basically I am wanting to make sure I have the text right as well as implementing each via htaccess as opposed to a meta tag? Am I missing anything massive? I am running a static website (html / css / javascript w/o a web-based cms like WordPress). Thoughts? Particularly etags and the last entry about leaked php version? eTags ETag: If-None-Match: "33a64df551425fcc55e4d42a148795d9f25f89d4" Security Headers - CSP: Frame-ancesetors Header always append X-Frame-Options SAMEORIGIN via htaccess or Content-Security-Policy: frame-ancestors 'none'; …

  29. Part of my web site design (PHP running on Linux server) sends a link to the user via e-mail containing a 32 character key as a GET parameter. So the link looks like this: https://sylvesterbradley.org/swchoir/edit_member.php?x=1&key=0V88jzAfEQfZ6QcIID5BdeuLvQxuGOiG. The user is asked to click the link, which takes him to a page where (if the link matches what we have stored in the database, and has not time expired) he can enter a new password. Sometimes when such a link is clicked, the $_GET variable is empty, i.e. is equal to []. Why might this be? How do I find out what is going wrong and fix it? Thank you - Rowan

  30. Started by rowan.bradley,

    I am working on a website developed in PHP to run on a Linux Apache server. After some recent changes my session variables seem to have gone haywire. One of my pages creates a new session and then logs the value of the $_SESSION array using var_dump. Here's the result: [25-Jun-2021 11:53:00.220 BST 1] on , L_TRACE Session ID = 500qbjglhu2vsvupfp5810kmi1, $_SESSION = {"54b4368deba7f09e24d876746ae2b9db3923d76b45e772c946201c80d3b23a289c629d230a0e5493e91a048b1532df4e76cb12ffce6d065e38179519f8f067e9":{"form_security_tokens":{"account_update":{"20210624":[]}, "permalink":{"20210624":{"20210624xM1EM0WHHtO5uMOLzhdWZXl_1yiPnbaw":true, "20210624M9lPBD1YzVXM8KLaM7rwJnkDg9Ftz…

  31. Can anyone tell me how to host Email and Web Hosting on Different Servers? my hosting provider is not providing bulk mail service, so I want to setup own smtp server for bulk emailing.

    • 2 replies
    • 2.1k views
  32. Started by Red11,

    Hi all, I have 2 pieces to my htaccess that seem to have conflicting interests. The first block is what I have added as the site is built with Vue and the tutorial suggested this. The second is from my old site and forwards requests without 'www' to the address with 'www'. <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.html$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.html [L] RewriteCond %{HTTP_HOST} ^address.co.uk [NC] RewriteRule ^(.*)$ http://www.address.co.uk/$1 [L,R=301,NC] </IfModule> The non 'www' url forwards correctly when on the homepage, but if someone di…

    • 1 reply
    • 2.1k views
  33. Hi Gang, So, I've a bit of a pickle and I'm not 100% sure as to why. I'm using a custom 404 served via htaccess. Here's the simple htaccess setup. Options +FollowSymlinks RewriteEngine On RewriteBase / ErrorDocument 404 /404.php The problem is when requesting a non-existent .php file in the public root I get 'File not found.' and not the custom 404. Here's some examples; domain.com/fish - Custom 404 shows domain.com/fish/ - Custom 404 shows domain.com/fish.html - Custom 404 shows domain.com/fish.jpg - Custom 404 shows domain.com/fish.php - I get File Not Found. domain.com/j/fish.php - Custom 404 shows Any ideas as to why a non-exis…

  34. Started by Red11,

    Hi there, I have built a site sith Vue.js and wanted to protect some pages with a password. From what I have seen, using .htaccess is a good method. But... Is there a (relatively) secure way when a user has entered the password they don't need to again for the rest of the visit? I was thinking storing a cookie or something, but is this easily hackable? Thanks

  35. hello friends, Still new to node I was follwing a tutorial on how touse Joi9 validation with node express but i am getting this error here is my code app.js const express = require('express'); const path = require('path'); const Joi = require('joi'); const bodyParser = require('body-parser'); const app = express(); //const hostname = '127.0.0.1'; app.use('/public',express.static(path.join(__dirname,'static'))); app.use(bodyParser.urlencoded({extended:false})); app.use(bodyParser.json()); //const port = 3000; app.get('/',(req,res)=>{ res.sendFile(path.join(__dirname,'static','index.html')); }); app.post('/',(req,…

  36. Started by beatroot,

    Hi guys, i'm evaluating technologies to use for a large database driven project with a lot of coding-heavy custom functionality (extensive community functions, event-calendars, APIs, etc etc ). later on there will also be mobile apps. most data will be filled up automatically, fetched from other websites and web-services, and then maintained. many tables will be hundreds of thousands of records in size. there will be some manual creating of articles or editing of fetched data, but editing is not a main concern. scalability and speed is important, we do expect quite some traffic on it. i guess what i'm looking for is a CMS that can work with a relatio…

  37. Started by GusGF,

    ......and I've no idea what the hell I'm doing. 😬 Okay let me explain I'm going back over a Wordpress course I did on Udemy where the now AWOL instructor implemented a automated workflow for us to use whereby anytime we typed PHP or JS the webpage would reload automatically, and it's working, actually it's working too fast for me. This time round for some reason it's driving me bonkers cos when I'm writing my code the page is recompiled before I can even finish typing a complete line of code! A parse error is then generated and I have to manually refresh the page when I'm done to clear the error as it doesn't get automatically refreshed due to the error, which sort o…

  38. Started by sash_oo7,

    hello friends, I was trying to show a message using node server but when i typed localhost:3000 in my browser it shows nothing here is my code const http = require('http'); const server = http.createServer((req,res)=>{ res.write('hello world from node js'); res.end(); }); server.listen('3000');

  39. Hi all =) newbie here...just trying to figure out PHP for the first time so I can add a Contact Form to my website.... I have been following an article written by my web hosting provider on how to create a basic PHP to email script (Link Here) which is working fine when I copy and paste the code, but when I try to add my own elements (a single checkbox for example), it seems to break the code and gives me 500 errors. I managed to add a single HTML Text Input which emails me the results as required (see $messagesubject in the PHP below), but when I add a checkbox ($sub), I cannot figure out what code I need to use :/ The basic concept of the form is Name, Email,…

    • 3 replies
    • 2.7k views
  40. Started by Red11,

    I am new to PHP, and have been dropped in to a job a little out of my depth to try and work something out. I have a list of items and quantities from different departments. I am trying to count the number of items from a certain group of departments in that list, and assign that number to a variable. eg: item 1 has qty of 1 and is from category_id 2 item 2 has qty of 1 and is from category_id 5 item 3 has qty of 1 and is from category_id 3 How would I get that to work from the following? $group1 = function () { return array_sum( return array_map( function ($item) { return count(array_intersect($item->produc…

    • 2 replies
    • 2.1k views
  41. Hi guys, One of my clients wants to build a file storage system (similar to Google Drive) for a mobile APP. He asked me to build an API for this (using Laravel). But I don't know where to start. I can build the authentication just fine but I don't know how to do the rest. How should I make an API for creating a Folder, Manage access, Share Links for a folder, copy, move, etc... Please, someone, help me. I don't know which endpoints to use for this. I am posting a link to a doc file for this project. https://drive.google.com/file/d/1w3F3nK3cGCexIVyW7FsERJ6AcqtLJFk1/view Thanks again, Fahim

  42. Started by BenB,

    I've been setting up a website for a client and have got into a right mess! The website was held with a company, over a decade ago, recently they went out of business (But were bought out by Plusnet - and supplied free hosting - result!) But the hosting was basic. I set up a new wordpress site under new hosting, with Bluehost, using a temporary name until we were ready to go live. Yesterday I was asked to go live with the new design. So I did two things at once - Transfered ownership of the domain name to a new owner, and at the new owner's side initiated the incoming transfer and also set new nameservers so once it arrived it would also be pointing to the …

  43. Started by D53 Media,

    Hi, I have a website on Bluehost that has free 2 email address attached to a domain. I am migrating all of my websites over to another host. The Emails have only ever been accessed via Bluehosts online mail portal Does anyone know of an easy way of migrating the email accounts without losing existing emails? Regards, Dave Rudge

  44. Started by Krush,

    Bonjour Lorsque je visite mon site Web avec Google Chrome et que j'obtiens parfois ce message d'erreur "ERR_CONNECTION_REFUSED". Je pensais que c'était à cause d'un logiciel ou d'un pare-feu bloquant mon site , alors j'ai fait une analyse complète en utilisant Malwarebytes. L'application n'a rien trouvé! Je pensais aussi que c'était à cause de mon navigateur, j'utilise toujours chrome mais l'erreur se produit même avec Firefox. Je suis un peu perdue. Toute aide serait grandement appréciée. Translation: Hello When I visit my website with Google Chrome and sometimes I get this "ERR_CONNECTION_REFUSED" error message. I thought it was because of some software or…

    • 2 replies
    • 2.5k views
  45. Started by davep,

    trying to help my friend move her domain name to another server. Last time i did this was about 15 years ago and getting confused the domain name is balsan.fi and we (my boss who i freelance for) is the registrar account holder so it's currently here ns.kpk.fi ns1.kosila.fi and trying to change the nameservers to use with new hosting with Duda please see attached screen shots with info of nameservers and what duda require. i just need some instructions for a dummy so i know what to do - do i remove old nameservers and add new ones or.. ?

  46. Started by ianhy,

    I have just integrated https://github.com/coryetzkorn/php-store-hours into my website and it's working perfect but the exceptions is not working and also if the exceptions be date ranges so the opening times for dates 7/4/2020 to 7/31/2020 instead of listing the individual dates, below is the current code <?php // REQUIRED // Set your default time zone (listed here: http://php.net/manual/en/timezones.php) date_default_timezone_set('Europe/London'); // Include the store hours class require DIR . '/StoreHours.class.php'; // REQUIRED // Define daily open hours // Must be in 24-hour format, separated by dash // If closed for the day, leave blank (ex. sunday) // I…

  47. hello friends i am trying to insert data using mysqli prepeared statement this code works without using prepared <!DOCTYPE html> <html lang = "en"> <head> <title>Forms</title> <meta charset = "utf-8"> <meta name = "viewport" content = "width=device-width , initial-scale =1"> <link rel="stylesheet" href="css/bootstrap.min.css"> <script src = "js/jquery-3.4.1.min.js"></script> <script src = "js/bootstrap.min.js"></script> <style> </style> </head> <body> <?php require("db.php"); //if form submitted ,insert values into th…

    • 0 replies
    • 2.1k views
  48. Started by BenB,

    Forgive me if this is in the wrong section! I've designed my website in the past using coding, in Dreamweaver, though I don't know what if doing a lot of the time, Google has gotten me through! I added a blog to my photography business website, using WordPress, in the folder /blog/, and bought a template in both WordPress and html, so the user couldn't really tell which of the sites they were in. The time has come I thought, to move the whole website to WordPress, doing all the edits in the WordPress dashboard makes a lot more sense than some in Dreamweaver, plus all plugins etc would be better if they were the same site-wide. So I've remade my hom…

  49. Started by NimbleJS,

    Any Node JS developers out there? I was wondering what is your back end database choice you prefer? Is MongoDB worth it? I have tried lokiJS and Pouch, and was wondering if scaling up to full Mongo is worth it? On other question.. I've only discovered 1 forum software written in NodeJS. Has anyone else found any forums for Node, or is php the defacto? Thanks in advance.

  50. Started by sash_oo7,

    Hello friends, I was following atutorial on how to make a php mysql forum i got the signup working in this thread but stuckwith sigin now everytime i click submit i see this error " Something went wrong while registering. Please try again later." here is my code <?php ini_set('display_errors','1'); error_reporting(E_ALL); //create_cat.php include 'connect.php'; include 'header.php'; echo '<div class="col-md-12">'; echo '<h3>Sign in</h3>'; /*first check if the user is already signed in */ if(isset($_SESSION['signed_in']) && $_SESSION['signed_in'] == true) { echo '<div class="alert alert-in…

    • 0 replies
    • 2k views

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.