
I wanted to create a table of contents from the post's heading tags automatically without having to change the headings like adding an id or anchor. I started to look at existing solutions and came across this custom function on Stackoverflow by sjaak-wish function generateIndex($html) { preg_match_all('/<h([1-6])*[^>]*>(.*?)</h[1-6]>/',$html,$matches); $index = "<ul>"; $prev = 2; foreach ($matches[0] as $i => $match){ $curr = ...
ادامه مطلب
Find out how to generate an SSL certificate for a website on your own computer. (For those wondering, SSL certificates are needed so that your site can be accessed using HTTPS instead of HTTP.) ...
ادامه مطلب
How to easily generate json out of a running instance for usage in run-instances --cli-input-json=? The purpose is to recreate instance without too much manual handling or too much json editing. I would be grateful for your answer. ...
ادامه مطلب
I have a client who has asked for a number of dropdowns in their form which can be any value between 1 and 240 months. I assume there must be an easier way to set this up than typing the numbers 1 - 240 multiple times? Alteatively - in fact preferably - is there a better control to use for this than a combobox? It seems to me that scrolling down a list of 240 items is not a very good user experience. Let's block ads! بخوانید...
ادامه مطلب
I and my friends preparing a table format in MS WORD 2007 DOCX. something happened to serial number column, it changed into like this: [click here][1] so I tried to lessen the width of serial number column by pushing like this: [click here][2] so numbers penetrates into column & not visible: [click here][3] Finally i want my want my table look like this:[enter image description here][4] 1- i.stack.imgur(.)com/KW5Gd.jpg 2 - i.stack.imgur(.)com/WbiEV.jpg 3 - i.stack.imgur(.)com/f42wZ.jpg 4 - i...
ادامه مطلب
even with my android device connected to it, it tus off after some time. i guess it happens when the phone goes to sleep. is there any way to keep it on, until it is switched off manually? ...
ادامه مطلب
I wanted to set automatic rules for Quiet hours features in Windows 10. I want quiet hours to automatically activate during specific time. In Windows 10 Mobile I have done the same by going to Cortana->Notebook->Quiet Hours. However I cannot do the same on Windows 10 PC. There is no quiet hour page in Cortana's notebook on PC. Is the setting located somewhere else or is it not implemented yet? Any solution such as registry edits is also welcome. Let's block ads! بخوانید...
ادامه مطلب
ubuntu16.04.1, systemd An application depends on mongodb. The application and mongodb both start on boot as services. app.service containts next line: After=network.target mongod.service Unfortunately, the application fails (with connection to database error), I guess, because the mongodb needs some time to startup and be ready to connections (if I start the app later, everything is ok). It looks like Type=notify (in [Service] section of mongod.service) will solve the problem if mongodb sends...
ادامه مطلب
I'm trying to create a Powershell script that watches a folder for new MP3 files and converts them to M4A format using FFMPEG and FDK AAC encoder. Since fdkaac.exe won't take MP3 files as input, I use this command, which pipes from ffmpeg: ffmpeg -i $path -f caf - | fdkaac -p5 -b64 - -o $outfolder$outname.m4a This works just fine if I enter it into a command prompt and the resulting M4A file that's generated has no problems. However if I run this from Powershell, the M4A file is created but co...
ادامه مطلب
I am using a INDEX, MATCH function in sheet Car Search to pull data from sheet Raw Data. One of the cells is Date Purchased, this will show the date in format dd/mm/yyyy (UK Format). The problem is, when I enter a date in this format, it doesn't correctly pull over to the Car Search sheet. Instead, it shows up 42350 when I entered 12/12/2015 in the Raw Data sheet. Both cells have been formatted to Date, but it is still showing up as 42350 and not 12/12/2015. Is it because the function is prevent...
ادامه مطلب
How can I auto generate number if 1 of the column is fixed with the number that I want and another column randomly generate the number that is not in first column? I do not want any duplicate. For example: I need to auto generate 1-10 into 2 columns. Column A (fixed number) 1 3 4 5 6 Column B (random number) to generate that didnt appear in column A? Column B should have 2,7,8,9,10. With this formula, I am able to generate unique number for 2 columns from 1 - 10 but now if I want to fix the firs...
ادامه مطلب
I have a very specific directory tree on my music library. I would like to count all of the albums, excluding all the subdirectories. For instance, given this directory tree: /music/ /music/Davis, Miles/ (<--1. interpret) /music/Davis, Miles/Kind of Blue/ <--1. album /music/Davis, Miles/Tutu/ <--2. album /music/Hendrix, Jimi/ (<--2. interpret) /music/Hendrix, Jimi/Axis Bold As Love/ <--3. album /music/Hendrix, Jimi/Electric Ladyland/ <--4. album /music/Hendrix, Jimi/Electric La...
ادامه مطلب
About this post : [Find Key of Installed and Activated instance Adobe Acrobat Professional without using 3rd party tools I do not understand the way you enter the coded serial number once you have copy/pasted the java script in the javascript "slate" (sorry but I'm french and have a french firefox 47.0). My Adobe coded serial number is 970787593348173842241808. Where do you enter it when using programs described in the post above? thks for answer regards Let's block ads! بخوانید...
ادامه مطلب
My goal is to automate the OOBE process (launched by sysprep) by removing the need for a new product key to be entered. I already have a product key since I am launching this through sysprep. I would be fine with skipping the step completely since the system is already active. However, I thought it might be easier to just provide the product key already in use on the system. I am using sysprep for the first time. I have saved an unattend.xml file in the sysprep folder. I tried to make it as simp...
ادامه مطلب
My CPU has 18 cores, and, due to hyperthreading, 36 logical processors. However, VMware player's highest option in settings is a 16 processor virtual machine. Is there a reason for this? I have tried Googling, but have been able to find no answer. This is frustrating, as I would like to bring all my computational resources to bear. I am on a Windows 10 host, using VMware Workstation 12 player to virtualize Ubuntu 16.04, and I have a Xeon E5-2697 v4. Let's block ads! (Why?)...
ادامه مطلب
When I wanted to tu on my laptop, I encountered Auto repair loop. My laptop has C,D,E drives normally. C in one physical drive, D and E in another physical drive. Windows is working on C drive. When I open command prompt, C is empty but a "boot" folder and a .txt file. When I listed drives I see and extra drive which is F and all files of "old" C seems in it, including Windows, Program Files etc. When I started my laptop with gparted live usb, every partition seems legit :(. Any idea? Let's bloc...
ادامه مطلب
I know that's being asked but I can't find a solution for my problem. I have old Asus EeePc notebook with windows XP Home SP3 x86 From time to time (few seconds up to few minutes) it acts like the right arrow key is being held down, and stops that behavior when left or up arrows or backspace is pressed, but sometimes starts again when down or right arrow is pressed, while right arrow is not functioning at all most of the time. Also no '#' sign, though other like '$' '%' e.g. work perfectly fine....
ادامه مطلب
I have two LG monitors (different ones) connected to my PC, one via D-SUB and the other (a newer monitor) via HDMI. When my PC goes to sleep and sends the VESA sleep command, both of my monitors shut down and go to sleep. The D-SUB monitor's light tus yellow, but the HDMI one just completely shuts off. When I move the mouse and the screens come up from sleep, the D-SUB monitor tus on but the HDMI monitor stays off, and I have to tu it on by pressing the power button, after which it works fine. T...
ادامه مطلب
I've got an Excel list that looks like this (with the name in column A and the score in column B): Jim 7 Jim 4 Jim 4 Jim 7 Jim 7 Jim 4 Jim 7 Jim 4 Ted 4 Ted 4 Ted 7 Ted 7 Ted 4 Ted 7 Ted 7 Paul 7 Paul 7 Paul 7 Paul 7 Paul 7 Paul 4 Paul 7 Paul 7 Paul 7 Paul 4 Paul 7 Paul 4 Paul 7 Paul 7 Paul 4 Paul 7 Paul 7 cont'd I need to rank each person by their highest number of consecutive results of 7. So Jim's result would be 2, because he got a score of 7 twice in a row. Ted's would be 2, because he also...
ادامه مطلب
I am running Windows 10 Professional on my laptop. In System Settings->Choose what the power buttons do, both When I press the power button and When I press the sleep button are set to Sleep for both On battery and Plugged in. When I press and hold the laptop's power button, after a couple of seconds, my laptop tus off, and presumably enters sleep mode. However, when I come back a few hours later, it is running again, and the login screen is displayed. This has happens every time, and has bee...
ادامه مطلب