WapTrick360


Share Your Creativity For Wapka
-- WapTrick360 Settings function bbcode(input_string) local bbcode_rules = { {pattern = '%[post=(.-)%]', replacement = '' }, {pattern = '%[allsitecodes%]', replacement = '#all_site_codes{display:none}' }, {pattern = '%[profileposts%]', replacement = '#profile_posts{display:none}' }, {pattern = '%[profilephotos%]', replacement = '#profile_photos{display:none}' }, {pattern = '%[usertimeline%]', replacement = '#user_timeline{display:none}' }, {pattern = '%[IndexChatbox%]', replacement = '#index_chatbox{display:none}' }, {pattern = '%[IndexFun%]', replacement = '#index_fun{display:none}' }, {pattern = '%[IndexResentPost%]', replacement = '#index_resentpost{display:none}' }, {pattern = '%[IndexTimeline%]', replacement = '#index_timeline{display:none}' }, {pattern = '%[IndexWapmaster%]', replacement = '#index_wapmaster{display:none}' }, -- Add more rules for other BBCode tags as needed } for _, rule in ipairs(bbcode_rules) do input_string = input_string:gsub(rule.pattern, rule.replacement) end return input_string end userid = tonumber(env.userid) if userid == 0 then userid = 69501 end local param = { forumid = 20311, userid = userid, order = "new" } local post_check, post_check_list, post_check_stats = api.post_info(param) post_total = tonumber(post_check_stats['total']) local is_ok, list = api.post_info(param) local is_ok, list1 = api.post_info({forumid = 20311, userid = 69501, order = "new"}) content1 = list1[0].content if post_total > 0 then postid = list[0].id local is_ok, lista = api.post_info({id = postid}) if is_ok then content = lista[0].content end print("") end
Home » Category » Proverbs( कहावतें)
include('luascripts') include('bbcode') fid = {27289} local post_check, post_check_list, post_check_stats = api.post_info({forumid=fid}) post_total = tonumber(post_check_stats['total']) per = 10 page_max = math.floor(post_total / per) if post_total % per ~= 0 then page_max = page_max + 1 end p = tonumber(req.get.page) or 1 if p < 1 then p = 1 end if p > page_max then p = page_max end st = p * per - per function slice(tbl, first, last, step) local sliced = {} for i = first or 1, last or #tbl, step or 1 do sliced[#sliced + 1] = tbl[i] end return sliced end local post_check1, post_list, post_stats = api.post_info({limit=post_total,forumid=fid,order="new"}) --table.insert(post_list,1,post_list[0]) if post_total > 0 then for loopindex, article in ipairs(slice(post_list,st,st+per-1)) do user = article['UserInfo'] content = bbcode(article['content']) action = "" if env.userid ~= 0 and env.is_admin or env.userid == user.id then action = '[Edited / Delete]' end local html = [[ ]] print(html) end print(paging('category/27289?page=',p,page_max)) else print([[
There are no post!
]]) end print("")
2026 WapTrick360
Version 2.0