I’ll let the pictures speak for themselves.
If you’d like to update a production web site or application from SVN but are worried about the security implications of having .svn directories exposed to the public, see the following simple solution:
I had a working report in Access 2007. It sourced a query called Rosters. The report grouped by several course-related fields, and then in the detail section, it printed names and student IDs. The effect was a stack of printable student rosters.
Then I needed to change the Rosters query to do a little filtering. I did that, saved it, and ran the report again. Suddenly, all the student details were outputting “#Name?”
The usual culprit is changing the names of fields in the query, but that was not the problem this time. The report has simply gotten disconnected from its data source in ONLY the details section. That’s what made it so weird.
The resolution was to click the “Add Existing Fields” in the menu, then drag in one of those fields to the details section, then save, then run the report, then get rid of the extraneous field. From then on, it preserved the connection.
A standard LAMPP install on Ubuntu hosting a wordpress site is going to yield a screen asking for connection information if you try to install a plugin using the integrated installer. To get around this, fix the ownership of the wordpress directory and the permissions.
NOTE: what I’m about to tell you to do is NOT SECURE. It’s OK for local development in a closed environment where no one is trying to hack you. By following this, you’ll be allowed to install the plugins as expected, but you’ll be opening a major security hole in your system. I disclaim all responsibility for consequences of you following my advice.
That said, here’s what to do:
Note: replace ~/workspace/website-folder with the path to your website folder.
When you FTP the files, the permissions will not be kept, so it should be OK to develop like this and then upload it to a remote server, then tweak only the necessary permissions.
This is just here because I always forget how to do it:
[code]echo $form->input(‘fieldname’, array(‘options’=>array(‘1’=>’val1’, ‘3’=>’val2′ […]), ‘multiple’=>’checkbox’, ‘label’=>’Da Label’));[/code]
Want a single click button that will take your document, save it to PDF in a certain folder, then close the current document? It’s great when you need to machine-gun thrrough a bunch of document conversions.
1) open a word document
2) click the View tab in the Ribbon
3) click the Macros button, then click Record New Macro
4) Give it the name ‘PDFaliscious’ (don’t worry, you’ll never need to actually refer to or type that word)
5) Click the ‘assign to button’ button, then move PDFaliscious to the right-side list of commands (this will keep it within single-click access no matter where you are in word by adding it to the quick-access bar)
7) Click OK (you’re now in macro record mode)
8) Click Macro again in the View tab and select Stop Recording
9) Click Macro AGAIN in the View tab and select View Macros
10) Click PDFaliscious and then Edit
11) Highlight everything from Sub PDFaliscious() to the next End Sub (about 15 lines) and delete it.
12) Paste in the following
<div id="_mcePaste">Sub PDFaliscious()</div>
<div id="_mcePaste">' PDFaliscious Macro</div>
<div id="_mcePaste"> ActiveDocument.ExportAsFixedFormat OutputFileName:= _</div>
<div id="_mcePaste"> ActiveDocument.Path & ActiveDocument.Name & ".pdf" _</div>
<div id="_mcePaste"> , ExportFormat:=wdExportFormatPDF, OpenAfterExport:=False, OptimizeFor:= _</div>
<div id="_mcePaste"> wdExportOptimizeForPrint, Range:=wdExportAllDocument, From:=1, To:=1, _</div>
<div id="_mcePaste"> Item:=wdExportDocumentContent, IncludeDocProps:=True, KeepIRM:=True, _</div>
<div id="_mcePaste"> CreateBookmarks:=wdExportCreateNoBookmarks, DocStructureTags:=True, _</div>
<div id="_mcePaste"> BitmapMissingFonts:=True, UseISO19005_1:=False</div>
<div id="_mcePaste"> ActiveDocument.Close</div>
<div id="_mcePaste">End Sub</div>
13) Close the VB Editor.
Whenever you want to run this, click the new little yellow icon in the quick access toolbar, right next to the Microsoft soothing lozenge.
It’s complete bullshit that you have to fill out a form to get an e-mail link to the download. This post goes out to all the devs who are NOT GOING TO FILL OUT THAT FORM.
Shove it, Java, just shove it.
$ git clone /path/to/repo/*
Initialized empty Git repository in /path/to/file.ext/.git/
error: ‘/path/to/repo/file.ext’ does not look like a v2 bundle file
fatal: Could not read bundle ‘/path/to/repo/file.ext’.
Fortunately, it happened after I’d just done a serious site-wide rename of a bunch of files, and I decided to try cleaning the repository.
This solved everything:
$ git gc /path/to/repo