Skip to content

Commit

Permalink
Add hosting imghippo.com
Browse files Browse the repository at this point in the history
Update version info
  • Loading branch information
zenden2k committed Oct 27, 2024
1 parent 6faa614 commit 0a49fe0
Show file tree
Hide file tree
Showing 5 changed files with 54 additions and 4 deletions.
Binary file added Data/Favicons/imghippo.com.ico
Binary file not shown.
38 changes: 38 additions & 0 deletions Data/Scripts/imghippo.nut
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
function UploadFile(fileName, options) {
local key = ServerParams.getParam("apiKey");
if (key == "") {
WriteLog("error", "[imghippo.com] API key not set!");
return 0;
}
local name = ExtractFileName(fileName);
local mime = GetFileMimeType(name);
nm.setUrl("https://api.imghippo.com/v1/upload");
nm.addQueryParam("api_key", key);
nm.addQueryParam("format", "json");
nm.addQueryParamFile("file", fileName, name, mime);
nm.doUploadMultipartData();

if (nm.responseCode() == 200) {
local sJSON = nm.responseBody();
local t = ParseJSON(sJSON);
if (t != null) {
if ("success" in t && t.success) {
options.setViewUrl(t.data.view_url);
options.setDirectUrl(t.data.url);
return 1;
} else {
if ("message" in t && t.message != null) {
WriteLog("error", "[imghippo.com] " + t.message);
}
}
}
}

return 0;
}

function GetServerParamList() {
return {
apiKey = "API key"
}
}
6 changes: 6 additions & 0 deletions Data/servers.xml
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@
</Actions>
<Result DownloadUrlTemplate="stub" ThumbUrlTemplate="stub"/>
</Server>
<!-- Blocked by RKN ? -->
<Server Name="hostingkartinok.com" Authorize="1" Debug="0" WebsiteUrl="https://hostingkartinok.com" RegistrationUrl="https://hostingkartinok.com/register.php">
<Actions>
<Action Type="upload" Url="https://hostingkartinok.com/login.php" PostParams="autologin=1;email=$(_LOGIN);password=$(_PASSWORD);login=Войти" OnlyOnce="1" />
Expand Down Expand Up @@ -432,6 +433,11 @@
</Actions>
<Result DownloadUrlTemplate="stub"/>
</Server>
<Server Name="imghippo.com" Authorize="2" Type="image" Plugin="imghippo" NeedPassword="0">
<Actions>
</Actions>
<Result ImageUrlTemplate="stub" DownloadUrlTemplate="stub"/>
</Server>
<!-- 429 Too Many Requests
<Server Name="pasteboard.co" MaxThreads="1">
<Actions>
Expand Down
4 changes: 2 additions & 2 deletions Source/Image Uploader.rc
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ FONT 8, "MS Shell Dlg", 400, 0, 0xCC
BEGIN
DEFPUSHBUTTON "&OK",IDOK,216,293,52,15
LTEXT "build 1234\nUsing curl",IDC_IMAGEUPLOADERLABEL,158,25,101,20
CTEXT "� 2007-2024 by Sergey Svistunov. All rights reserved.",IDC_STATIC,52,72,189,11
CTEXT "� 2007-2024 Sergey Svistunov. All rights reserved.",IDC_STATIC,52,72,189,11
CONTROL "",IDC_STATICLOGO,"Static",SS_BITMAP,37,18,15,13
CTEXT "Image Uploader",IDC_IMAGEUPLOADERLABEL2,80,14,148,12
RTEXT "VERSION",IDC_CURLINFOLABEL,77,25,68,9
Expand Down Expand Up @@ -1987,7 +1987,7 @@ BEGIN
VALUE "FileDescription", "Image Uploader"
VALUE "FileVersion", "1.3.3.0"
VALUE "InternalName", "Image Uploader"
VALUE "LegalCopyright", "Copyright 2007-2024 by Sergey Svistunov (https://svistunov.dev)"
VALUE "LegalCopyright", " 2007-2024 Sergey Svistunov (https://svistunov.dev)"
VALUE "OriginalFilename", "Image Uploader.exe"
VALUE "ProductName", "Image Uploader"
VALUE "ProductVersion", "1.3.3.0"
Expand Down
10 changes: 8 additions & 2 deletions Source/ShellExt/ExplorerIntegration.rc
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,10 @@ BEGIN
BLOCK "040904e4"
BEGIN
VALUE "Comments", "Image Uploader shell extension"
VALUE "FileDescription", "Image Uploader 1.3.x shell extension"
VALUE "FileDescription", "Image Uploader 1.4.x shell extension"
VALUE "FileVersion", "1.1.0.2"
VALUE "InternalName", "ExplorerIntegration.dll"
VALUE "LegalCopyright", "Copyright 2009-2019 Sergey Svistunov"
VALUE "LegalCopyright", " 2009-2024 Sergey Svistunov"
VALUE "OriginalFilename", "ExplorerIntegration.dll"
VALUE "ProductName", "Image Uploader"
VALUE "ProductVersion", "1.3.2.0"
Expand All @@ -90,8 +90,10 @@ END
//

IDR_EXPLORERINTEGRATION REGISTRY "ExplorerIntegration.rgs"

IDR_ISHELLCONTEXTMENU REGISTRY "IShellContextMenu.rgs"


/////////////////////////////////////////////////////////////////////////////
//
// Icon
Expand All @@ -100,10 +102,14 @@ IDR_ISHELLCONTEXTMENU REGISTRY "IShellContextMenu.rgs"
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDI_ICONINFO ICON "Res\\icon-info-16px.ico"

IDI_ICONMOVIE ICON "Res\\icon-movie-16px.ico"

IDI_ICONUPLOAD ICON "Res\\icon-upload-16px.ico"

IDI_ICONMAIN ICON "..\\Res\\new-icon.ico"


/////////////////////////////////////////////////////////////////////////////
//
// String Table
Expand Down

0 comments on commit 0a49fe0

Please sign in to comment.